python-jupyter-core/use_rpms_paths.patch

38 lines
1.2 KiB
Diff
Raw Normal View History

From: toddrme2178@gmail.com
Date: 2017-09-20
Subject: Use rpm paths
Use single-line paths. These must be replaced with the appropriate
system paths in the .spec file.
---
- Update to 5.1.1 * Only prefer envs owned by the current user #323 (@minrk) * Don't treat the conda root env as an env #324 (@minrk) - Release 5.1.0 * Add run_sync and ensure_async functions #315 (@davidbrochart) - Release 5.0.0 ## Major Changes * Prefer Environment Level Configuration. We now make the assumption that if we are running in a virtual environment, we * should prioritize the environment-level sys.prefix over the user-level paths. Users can opt out of this behavior by setting JUPYTER_PREFER_ENV_PATH, which takes precedence over our autodetection. * Migrate to Standard Platform Directories. In version 5, we introduce a JUPYTER_PLATFORM_DIRS environment variable to opt in * to using more appropriate platform-specific directories. We raise a deprecation warning if the variable is not set. In version 6, JUPYTER_PLATFORM_DIRS will be opt-out. In version 7, we will remove the environment variable checks and old directory logic. * Drop Support for Python 3.7 * We are dropping support for Python 3.7 ahead of its official end of life, to reduce * maintenance burden as we add support for Python 3.11. * Use platformdirs for path locations #292 (@blink1073) * Try to detect if we are in a virtual environment and change path precedence * accordingly #286 (@jasongrout) * Add current working directory as first config path #291 (@blink1073) * Fix inclusion of jupyter file and check in CI #276 (@blink1073) OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-jupyter-core?expand=0&rev=28
2022-12-25 20:40:52 +00:00
Index: jupyter_core-5.1.1/jupyter_core/paths.py
===================================================================
- Update to 5.1.1 * Only prefer envs owned by the current user #323 (@minrk) * Don't treat the conda root env as an env #324 (@minrk) - Release 5.1.0 * Add run_sync and ensure_async functions #315 (@davidbrochart) - Release 5.0.0 ## Major Changes * Prefer Environment Level Configuration. We now make the assumption that if we are running in a virtual environment, we * should prioritize the environment-level sys.prefix over the user-level paths. Users can opt out of this behavior by setting JUPYTER_PREFER_ENV_PATH, which takes precedence over our autodetection. * Migrate to Standard Platform Directories. In version 5, we introduce a JUPYTER_PLATFORM_DIRS environment variable to opt in * to using more appropriate platform-specific directories. We raise a deprecation warning if the variable is not set. In version 6, JUPYTER_PLATFORM_DIRS will be opt-out. In version 7, we will remove the environment variable checks and old directory logic. * Drop Support for Python 3.7 * We are dropping support for Python 3.7 ahead of its official end of life, to reduce * maintenance burden as we add support for Python 3.11. * Use platformdirs for path locations #292 (@blink1073) * Try to detect if we are in a virtual environment and change path precedence * accordingly #286 (@jasongrout) * Add current working directory as first config path #291 (@blink1073) * Fix inclusion of jupyter file and check in CI #276 (@blink1073) OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-jupyter-core?expand=0&rev=28
2022-12-25 20:40:52 +00:00
--- jupyter_core-5.1.1.orig/jupyter_core/paths.py
+++ jupyter_core-5.1.1/jupyter_core/paths.py
@@ -219,10 +219,7 @@ else:
else: # PROGRAMDATA is not defined by default on XP.
SYSTEM_JUPYTER_PATH = [os.path.join(sys.prefix, "share", "jupyter")]
else:
- SYSTEM_JUPYTER_PATH = [
- "/usr/local/share/jupyter",
- "/usr/share/jupyter",
- ]
+ SYSTEM_JUPYTER_PATH = [ @_datadir_jupyter_@ ]
- Update to 5.1.1 * Only prefer envs owned by the current user #323 (@minrk) * Don't treat the conda root env as an env #324 (@minrk) - Release 5.1.0 * Add run_sync and ensure_async functions #315 (@davidbrochart) - Release 5.0.0 ## Major Changes * Prefer Environment Level Configuration. We now make the assumption that if we are running in a virtual environment, we * should prioritize the environment-level sys.prefix over the user-level paths. Users can opt out of this behavior by setting JUPYTER_PREFER_ENV_PATH, which takes precedence over our autodetection. * Migrate to Standard Platform Directories. In version 5, we introduce a JUPYTER_PLATFORM_DIRS environment variable to opt in * to using more appropriate platform-specific directories. We raise a deprecation warning if the variable is not set. In version 6, JUPYTER_PLATFORM_DIRS will be opt-out. In version 7, we will remove the environment variable checks and old directory logic. * Drop Support for Python 3.7 * We are dropping support for Python 3.7 ahead of its official end of life, to reduce * maintenance burden as we add support for Python 3.11. * Use platformdirs for path locations #292 (@blink1073) * Try to detect if we are in a virtual environment and change path precedence * accordingly #286 (@jasongrout) * Add current working directory as first config path #291 (@blink1073) * Fix inclusion of jupyter file and check in CI #276 (@blink1073) OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-jupyter-core?expand=0&rev=28
2022-12-25 20:40:52 +00:00
ENV_JUPYTER_PATH: List[str] = [os.path.join(sys.prefix, "share", "jupyter")]
- Update to 5.1.1 * Only prefer envs owned by the current user #323 (@minrk) * Don't treat the conda root env as an env #324 (@minrk) - Release 5.1.0 * Add run_sync and ensure_async functions #315 (@davidbrochart) - Release 5.0.0 ## Major Changes * Prefer Environment Level Configuration. We now make the assumption that if we are running in a virtual environment, we * should prioritize the environment-level sys.prefix over the user-level paths. Users can opt out of this behavior by setting JUPYTER_PREFER_ENV_PATH, which takes precedence over our autodetection. * Migrate to Standard Platform Directories. In version 5, we introduce a JUPYTER_PLATFORM_DIRS environment variable to opt in * to using more appropriate platform-specific directories. We raise a deprecation warning if the variable is not set. In version 6, JUPYTER_PLATFORM_DIRS will be opt-out. In version 7, we will remove the environment variable checks and old directory logic. * Drop Support for Python 3.7 * We are dropping support for Python 3.7 ahead of its official end of life, to reduce * maintenance burden as we add support for Python 3.11. * Use platformdirs for path locations #292 (@blink1073) * Try to detect if we are in a virtual environment and change path precedence * accordingly #286 (@jasongrout) * Add current working directory as first config path #291 (@blink1073) * Fix inclusion of jupyter file and check in CI #276 (@blink1073) OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-jupyter-core?expand=0&rev=28
2022-12-25 20:40:52 +00:00
@@ -301,10 +298,7 @@ else:
else: # PROGRAMDATA is not defined by default on XP.
SYSTEM_CONFIG_PATH = []
else:
- SYSTEM_CONFIG_PATH = [
- "/usr/local/etc/jupyter",
- "/etc/jupyter",
- ]
+ SYSTEM_CONFIG_PATH = [ @_distconfdir_jupyter_@ ]
ENV_CONFIG_PATH: List[str] = [os.path.join(sys.prefix, "etc", "jupyter")]