- Update to 4.11.1

* Fix inclusion of jupyter file and check in CI by @blink1073 in
    #276
- Release 4.11.0
  * Use hatch backend by @blink1073 in #265
  * is_hidden: Use normalized paths by @martinRenou in #271
- Release 4.10.0
  * Include all files from jupyter_core by @jonringer in #253
- Refresh use_rpms_paths.patch

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-jupyter-core?expand=0&rev=24
This commit is contained in:
Benjamin Greiner 2022-08-01 18:07:11 +00:00 committed by Git OBS Bridge
parent c9c4bc60a8
commit a98d858959
5 changed files with 39 additions and 25 deletions

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:2e5f244d44894c4154d06aeae3419dd7f1b0ef4494dc5584929b398c61cfd314
size 73661

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:d69baeb9ffb128b8cd2657fcf2703f89c769d1673c851812119e3a2a0e93ad9a
size 74912

View File

@ -1,3 +1,16 @@
-------------------------------------------------------------------
Mon Aug 1 17:56:47 UTC 2022 - Ben Greiner <code@bnavigator.de>
- Update to 4.11.1
* Fix inclusion of jupyter file and check in CI by @blink1073 in
#276
- Release 4.11.0
* Use hatch backend by @blink1073 in #265
* is_hidden: Use normalized paths by @martinRenou in #271
- Release 4.10.0
* Include all files from jupyter_core by @jonringer in #253
- Refresh use_rpms_paths.patch
------------------------------------------------------------------- -------------------------------------------------------------------
Sun Mar 13 06:59:34 UTC 2022 - Ben Greiner <code@bnavigator.de> Sun Mar 13 06:59:34 UTC 2022 - Ben Greiner <code@bnavigator.de>

View File

@ -31,10 +31,8 @@
%define psuffix %{nil} %define psuffix %{nil}
%bcond_with test %bcond_with test
%endif %endif
%{?!python_module:%define python_module() python3-%{**}}
%define skip_python2 1
Name: python-jupyter-core%{psuffix} Name: python-jupyter-core%{psuffix}
Version: 4.9.2 Version: 4.11.1
Release: 0 Release: 0
Summary: Base package on which Jupyter projects rely Summary: Base package on which Jupyter projects rely
License: BSD-3-Clause License: BSD-3-Clause
@ -42,12 +40,11 @@ URL: https://github.com/jupyter/jupyter_core
Source0: https://files.pythonhosted.org/packages/source/j/jupyter_core/jupyter_core-%{version}.tar.gz Source0: https://files.pythonhosted.org/packages/source/j/jupyter_core/jupyter_core-%{version}.tar.gz
# PATCH-FIX-OPENSUSE -- use_rpms_paths.patch -- change paths so they are easy to replace at build time # PATCH-FIX-OPENSUSE -- use_rpms_paths.patch -- change paths so they are easy to replace at build time
Patch0: use_rpms_paths.patch Patch0: use_rpms_paths.patch
BuildRequires: %{python_module setuptools} BuildRequires: %{python_module base >= 3.7}
BuildRequires: %{python_module traitlets} BuildRequires: %{python_module hatchling}
BuildRequires: %{python_module pip}
BuildRequires: fdupes BuildRequires: fdupes
BuildRequires: jupyter-jupyter_core-filesystem
BuildRequires: python-rpm-macros >= 20210929 BuildRequires: python-rpm-macros >= 20210929
Requires: jupyter-jupyter_core-filesystem
Requires: python-traitlets Requires: python-traitlets
%if %{with libalternatives} %if %{with libalternatives}
BuildRequires: alts BuildRequires: alts
@ -67,7 +64,8 @@ Obsoletes: jupyter-jupyter_core < %{version}-%{release}
%endif %endif
BuildArch: noarch BuildArch: noarch
%if %{with test} %if %{with test}
BuildRequires: %{python_module jupyter-core} BuildRequires: %{python_module ipykernel}
BuildRequires: %{python_module jupyter-core = %{version}}
BuildRequires: %{python_module pytest-timeout} BuildRequires: %{python_module pytest-timeout}
BuildRequires: %{python_module pytest} BuildRequires: %{python_module pytest}
%endif %endif
@ -87,13 +85,16 @@ as a dependency by packages that require it.
# Set the appropriate hardcoded paths dynamically # Set the appropriate hardcoded paths dynamically
sed -i "s|\"_datadir_jupyter_\"|\"%{_datadir}/jupyter\"|" jupyter_core/paths.py sed -i "s|\"_datadir_jupyter_\"|\"%{_datadir}/jupyter\"|" jupyter_core/paths.py
sed -i "s|\"_sysconfdir_jupyter_\"|\"%{_sysconfdir}/jupyter\"|" jupyter_core/paths.py sed -i "s|\"_sysconfdir_jupyter_\"|\"%{_sysconfdir}/jupyter\"|" jupyter_core/paths.py
sed -i "/addopts/ s/--color=yes//" pyproject.toml
%build
%python_build
%install
%if !%{with test} %if !%{with test}
%python_install %build
%pyproject_wheel
%endif
%if !%{with test}
%install
%pyproject_install
%python_clone -a %{buildroot}%{_bindir}/jupyter %python_clone -a %{buildroot}%{_bindir}/jupyter
%python_clone -a %{buildroot}%{_bindir}/jupyter-migrate %python_clone -a %{buildroot}%{_bindir}/jupyter-migrate
%python_clone -a %{buildroot}%{_bindir}/jupyter-troubleshoot %python_clone -a %{buildroot}%{_bindir}/jupyter-troubleshoot
@ -106,10 +107,8 @@ sed -i "s|^#!%{_bindir}/env python$|#!%{__$python}|" %{buildroot}%{$python_sitel
%if %{with test} %if %{with test}
%check %check
pushd jupyter_core/tests
# test_jupyter_path_prefer_env does not work outside venvs: gh#jupyter/jupyter_core#208 # test_jupyter_path_prefer_env does not work outside venvs: gh#jupyter/jupyter_core#208
%pytest -k "not test_jupyter_path_prefer_env" %pytest -k "not test_jupyter_path_prefer_env"
popd
%endif %endif
%pre %pre

View File

@ -7,11 +7,13 @@ system paths in the .spec file.
--- ---
--- a/jupyter_core/paths.py Index: jupyter_core-4.11.1/jupyter_core/paths.py
+++ b/jupyter_core/paths.py ===================================================================
@@ -124,10 +124,7 @@ if os.name == 'nt': --- jupyter_core-4.11.1.orig/jupyter_core/paths.py
+++ jupyter_core-4.11.1/jupyter_core/paths.py
@@ -130,10 +130,7 @@ if os.name == "nt":
else: # PROGRAMDATA is not defined by default on XP. else: # PROGRAMDATA is not defined by default on XP.
SYSTEM_JUPYTER_PATH = [os.path.join(sys.prefix, 'share', 'jupyter')] SYSTEM_JUPYTER_PATH = [os.path.join(sys.prefix, "share", "jupyter")]
else: else:
- SYSTEM_JUPYTER_PATH = [ - SYSTEM_JUPYTER_PATH = [
- "/usr/local/share/jupyter", - "/usr/local/share/jupyter",
@ -19,9 +21,9 @@ system paths in the .spec file.
- ] - ]
+ SYSTEM_JUPYTER_PATH = ["_datadir_jupyter_"] + SYSTEM_JUPYTER_PATH = ["_datadir_jupyter_"]
ENV_JUPYTER_PATH = [os.path.join(sys.prefix, 'share', 'jupyter')] ENV_JUPYTER_PATH = [os.path.join(sys.prefix, "share", "jupyter")]
@@ -186,10 +183,7 @@ if os.name == 'nt': @@ -207,10 +204,7 @@ if os.name == "nt":
else: # PROGRAMDATA is not defined by default on XP. else: # PROGRAMDATA is not defined by default on XP.
SYSTEM_CONFIG_PATH = [] SYSTEM_CONFIG_PATH = []
else: else:
@ -31,5 +33,5 @@ system paths in the .spec file.
- ] - ]
+ SYSTEM_CONFIG_PATH = ["_sysconfdir_jupyter_"] + SYSTEM_CONFIG_PATH = ["_sysconfdir_jupyter_"]
ENV_CONFIG_PATH = [os.path.join(sys.prefix, 'etc', 'jupyter')] ENV_CONFIG_PATH = [os.path.join(sys.prefix, "etc", "jupyter")]