Tidying up Python

Christoph Kukulies kuku at kukulies.org
Wed Jul 16 16:38:51 UTC 2025


An afterword on my "tidying up python":

I still have a couple of errors coming up when starting jupyter from the terminal command line.
Searching the web revealed that one reason could be that I'm using a too much recent httpx version. My idea is to downgrade
to a previous version.

$ port installed | grep httpx
  httpx_select @0.1_0 (active)
  py311-httpx @0.28.1_0 (active)
  py313-httpx @0.28.1_0 (active)

Hoe do I find out, which the previous version is and how do I fall back to this version?



$ jupyter notebook
[I 2025-07-14 09:07:42.377 ServerApp] jupyter_lsp | extension was successfully linked.
[I 2025-07-14 09:07:42.385 ServerApp] jupyter_server_terminals | extension was successfully linked.
[I 2025-07-14 09:07:42.390 ServerApp] jupyterlab | extension was successfully linked.
[I 2025-07-14 09:07:42.394 ServerApp] notebook | extension was successfully linked.
[I 2025-07-14 09:07:42.980 ServerApp] notebook_shim | extension was successfully linked.
[I 2025-07-14 09:07:43.023 ServerApp] notebook_shim | extension was successfully loaded.
[I 2025-07-14 09:07:43.026 ServerApp] jupyter_lsp | extension was successfully loaded.
[I 2025-07-14 09:07:43.027 ServerApp] jupyter_server_terminals | extension was successfully loaded.
[I 2025-07-14 09:07:43.033 LabApp] JupyterLab extension loaded from /opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab
[I 2025-07-14 09:07:43.033 LabApp] JupyterLab application directory is /opt/local/Library/Frameworks/Python.framework/Versions/3.11/share/jupyter/lab
[I 2025-07-14 09:07:43.034 LabApp] Extension Manager is 'pypi'.
[W 2025-07-14 09:07:43.035 LabApp] Failed to instantiate the extension manager pypi. Falling back to read-only manager.
    Traceback (most recent call last):
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab/labapp.py", line 837, in initialize_handlers
        ext_manager = manager_factory(app_options, listings_config, self)
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab/extensions/__init__.py", line 46, in get_pypi_manager
        return PyPIExtensionManager(app_options, ext_options, parent)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab/extensions/pypi.py", line 130, in __init__
        self._httpx_client = httpx.AsyncClient(proxies=proxies)
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    TypeError: AsyncClient.__init__() got an unexpected keyword argument 'proxies'
[I 2025-07-14 09:07:43.040 ServerApp] jupyterlab | extension was successfully loaded.
[I 2025-07-14 09:07:43.044 ServerApp] notebook | extension was successfully loaded.
[I 2025-07-14 09:07:43.046 ServerApp] Serving notebooks from local directory: /Users/kuku/Documents/notebooks
[I 2025-07-14 09:07:43.046 ServerApp] Jupyter Server 2.13.0 is running at:
[I 2025-07-14 09:07:43.046 ServerApp] http://localhost:8888/tree?token=87ba4808ac1bd06a8245a519b0ced81bd37630eb01c2bcfd
[I 2025-07-14 09:07:43.046 ServerApp]     http://127.0.0.1:8888/tree?token=87ba4808ac1bd06a8245a519b0ced81bd37630eb01c2bcfd
[I 2025-07-14 09:07:43.046 ServerApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[C 2025-07-14 09:07:43.174 ServerApp]

    To access the server, open this file in a browser:
        file:///Users/kuku/Library/Jupyter/runtime/jpserver-63092-open.html
    Or copy and paste one of these URLs:
        http://localhost:8888/tree?token=87ba4808ac1bd06a8245a519b0ced81bd37630eb01c2bcfd
        http://127.0.0.1:8888/tree?token=87ba4808ac1bd06a8245a519b0ced81bd37630eb01c2bcfd
[I 2025-07-14 09:07:43.813 ServerApp] Skipped non-installed server(s): bash-language-server, dockerfile-language-server-nodejs, javascript-typescript-langserver, jedi-language-server, julia-language-server, pyright, python-language-server, python-lsp-server, r-languageserver, sql-language-server, texlab, typescript-language-server, unified-language-server, vscode-css-languageserver-bin, vscode-html-languageserver-bin, vscode-json-languageserver-bin, yaml-language-server
[W 2025-07-14 09:07:46.117 ServerApp] 404 GET /lab/api/settings/@jupyterlab/apputils-extension:kernels-settings?1752476866107 (127.0.0.1): Schema not found: /opt/local/Library/Frameworks/Python.framework/Versions/3.11/share/jupyter/lab/schemas/@jupyterlab/apputils-extension/kernels-settings.json
[W 2025-07-14 09:07:46.117 LabApp] wrote error: 'Schema not found: /opt/local/Library/Frameworks/Python.framework/Versions/3.11/share/jupyter/lab/schemas/@jupyterlab/apputils-extension/kernels-settings.json'
    Traceback (most recent call last):
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/tornado/web.py", line 1846, in _execute
        result = method(*self.path_args, **self.path_kwargs)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/tornado/web.py", line 3375, in wrapper
        return method(self, *args, **kwargs)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab_server/settings_handler.py", line 57, in get
        result, warnings = get_settings(
                           ^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab_server/settings_utils.py", line 379, in get_settings
        schema, version = _get_schema(schemas_dir, schema_name, overrides, labextensions_path)
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab_server/settings_utils.py", line 55, in _get_schema
        raise web.HTTPError(404, notfound_error % path)
    tornado.web.HTTPError: HTTP 404: Not Found (Schema not found: /opt/local/Library/Frameworks/Python.framework/Versions/3.11/share/jupyter/lab/schemas/@jupyterlab/apputils-extension/kernels-settings.json)
[W 2025-07-14 09:07:46.121 LabApp] 404 GET /lab/api/settings/@jupyterlab/apputils-extension:kernels-settings?1752476866107 (d68cda785160450bb8bb6be539c36b35 at 127.0.0.1) 9.37ms referer=http://localhost:8888/tree
[W 2025-07-14 09:07:46.498 ServerApp] 404 GET /lab/api/settings/@jupyter-notebook/notebook-extension:full-width-notebook?1752476866348 (127.0.0.1): Schema not found: /opt/local/Library/Frameworks/Python.framework/Versions/3.11/share/jupyter/lab/schemas/@jupyter-notebook/notebook-extension/full-width-notebook.json
[W 2025-07-14 09:07:46.499 LabApp] wrote error: 'Schema not found: /opt/local/Library/Frameworks/Python.framework/Versions/3.11/share/jupyter/lab/schemas/@jupyter-notebook/notebook-extension/full-width-notebook.json'
    Traceback (most recent call last):
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/tornado/web.py", line 1846, in _execute
        result = method(*self.path_args, **self.path_kwargs)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/tornado/web.py", line 3375, in wrapper
        return method(self, *args, **kwargs)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab_server/settings_handler.py", line 57, in get
        result, warnings = get_settings(
                           ^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab_server/settings_utils.py", line 379, in get_settings
        schema, version = _get_schema(schemas_dir, schema_name, overrides, labextensions_path)
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/jupyterlab_server/settings_utils.py", line 55, in _get_schema
        raise web.HTTPError(404, notfound_error % path)
    tornado.web.HTTPError: HTTP 404: Not Found (Schema not found: /opt/local/Library/Frameworks/Python.framework/Versions/3.11/share/jupyter/lab/schemas/@jupyter-notebook/notebook-extension/full-width-notebook.json)

--
Christoph




Christoph Kukulies
kuku at kukulies.org



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macports.org/pipermail/macports-users/attachments/20250716/8fa71077/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: Message signed with OpenPGP
URL: <http://lists.macports.org/pipermail/macports-users/attachments/20250716/8fa71077/attachment.sig>


More information about the macports-users mailing list