KeyError: 'Missing required environment $JUPYTERHUB_SERVICE_URL'

I create a new image and deploy it to jupyterhub, I spawn it and some error happends, how to solve thie?

jupyter-glhong.1.ux8r6lawedie@c3 | [D 2023-04-25 09:00:13.447 ServerApp] Paths used for configuration of jupyter_server_config:
jupyter-glhong.1.m3yxxnpyxwx4@c3 | [D 2023-04-25 09:00:45.226 TerminalsExtensionApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.f6rtu38p7tuf@c3 | [D 2023-04-25 08:59:42.045 TerminalsExtensionApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | /opt/conda/etc/jupyter/jupyter_server_config.d/jupyter_server_fileid.json
jupyter-glhong.1.kcr3209r0awy@c3 | [D 2023-04-25 08:59:14.468 FileIdExtension] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue {‘update’: {‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | /opt/conda/etc/jupyter/jupyter_server_config.d/jupyter_server_terminals.json
jupyter-glhong.1.f6rtu38p7tuf@c3 | [D 2023-04-25 08:59:42.047 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | /opt/conda/etc/jupyter/jupyter_server_config.d/jupyter_server_ydoc.json
jupyter-glhong.1.f6rtu38p7tuf@c3 | [I 2023-04-25 08:59:42.048 ServerApp] jupyter_server_terminals | extension was successfully linked.
jupyter-glhong.1.ux8r6lawedie@c3 | /opt/conda/etc/jupyter/jupyter_server_config.d/jupyterlab.json
jupyter-glhong.1.kcr3209r0awy@c3 | [D 2023-04-25 08:59:14.472 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | /opt/conda/etc/jupyter/jupyter_server_config.d/nbclassic.json
jupyter-glhong.1.f6rtu38p7tuf@c3 | [D 2023-04-25 08:59:42.055 YDocExtension] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | /opt/conda/etc/jupyter/jupyter_server_config.d/notebook_shim.json
jupyter-glhong.1.ux8r6lawedie@c3 | /opt/conda/etc/jupyter/jupyter_server_config.json
jupyter-glhong.1.f6rtu38p7tuf@c3 | [D 2023-04-25 08:59:42.057 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | [D 2023-04-25 09:00:13.448 ServerApp] Paths used for configuration of jupyter_server_config:
jupyter-glhong.1.kcr3209r0awy@c3 | [I 2023-04-25 08:59:14.474 ServerApp] jupyter_server_fileid | extension was successfully linked.
jupyter-glhong.1.f6rtu38p7tuf@c3 | [I 2023-04-25 08:59:42.058 ServerApp] jupyter_server_ydoc | extension was successfully linked.
jupyter-glhong.1.ux8r6lawedie@c3 | /home/sc_user/.local/etc/jupyter/jupyter_server_config.json
jupyter-glhong.1.f6rtu38p7tuf@c3 | [I 2023-04-25 08:59:42.058 JupyterHubSingleUser] Starting jupyterhub single-user server extension version 4.0.0
jupyter-glhong.1.kcr3209r0awy@c3 | [D 2023-04-25 08:59:14.489 TerminalsExtensionApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | [D 2023-04-25 09:00:13.449 ServerApp] Paths used for configuration of jupyter_server_config:
jupyter-glhong.1.m3yxxnpyxwx4@c3 | [D 2023-04-25 09:00:45.228 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.kcr3209r0awy@c3 | [D 2023-04-25 08:59:14.492 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | /home/sc_user/.jupyter/jupyter_server_config.json
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:13.455 ServerApp] Package jupyterhub took 0.0001s to import
jupyter-glhong.1.m3yxxnpyxwx4@c3 | [I 2023-04-25 09:00:45.229 ServerApp] jupyter_server_terminals | extension was successfully linked.
jupyter-glhong.1.f6rtu38p7tuf@c3 | [E 2023-04-25 08:59:42.059 JupyterHubSingleUser] Failed to load JupyterHubSingleUser server extension
jupyter-glhong.1.kcr3209r0awy@c3 | [I 2023-04-25 08:59:14.494 ServerApp] jupyter_server_terminals | extension was successfully linked.
jupyter-glhong.1.m3yxxnpyxwx4@c3 | [D 2023-04-25 09:00:45.236 YDocExtension] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:13.460 ServerApp] Package jupyter_server_fileid took 0.0046s to import
jupyter-glhong.1.kcr3209r0awy@c3 | [D 2023-04-25 08:59:14.512 YDocExtension] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:13.469 ServerApp] Package jupyter_server_terminals took 0.0086s to import
jupyter-glhong.1.m3yxxnpyxwx4@c3 | [D 2023-04-25 09:00:45.238 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:13.509 ServerApp] Package jupyter_server_ydoc took 0.0387s to import
jupyter-glhong.1.kcr3209r0awy@c3 | [D 2023-04-25 08:59:14.517 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.f6rtu38p7tuf@c3 | Traceback (most recent call last):
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:13.621 ServerApp] Package jupyterlab took 0.1105s to import
jupyter-glhong.1.kcr3209r0awy@c3 | [I 2023-04-25 08:59:14.521 ServerApp] jupyter_server_ydoc | extension was successfully linked.
jupyter-glhong.1.f6rtu38p7tuf@c3 | File “/opt/conda/lib/python3.10/site-packages/jupyterhub/singleuser/extension.py”, line 274, in wrapped
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:14.676 ServerApp] Package nbclassic took 0.0000s to import
jupyter-glhong.1.f6rtu38p7tuf@c3 | r = f(self, *args, **kwargs)
jupyter-glhong.1.kcr3209r0awy@c3 | [I 2023-04-25 08:59:14.524 JupyterHubSingleUser] Starting jupyterhub single-user server extension version 4.0.0
jupyter-glhong.1.ux8r6lawedie@c3 | [W 2023-04-25 09:00:14.679 ServerApp] A _jupyter_server_extension_points function was not found in nbclassic. Instead, a _jupyter_server_extension_paths function was found and will be used for now. This function name will be deprecated in future releases of Jupyter Server.
jupyter-glhong.1.f6rtu38p7tuf@c3 | File “/opt/conda/lib/python3.10/site-packages/jupyterhub/singleuser/extension.py”, line 472, in load_config_file
jupyter-glhong.1.kcr3209r0awy@c3 | [E 2023-04-25 08:59:14.524 JupyterHubSingleUser] Failed to load JupyterHubSingleUser server extension
jupyter-glhong.1.f6rtu38p7tuf@c3 | raise KeyError(“Missing required environment $JUPYTERHUB_SERVICE_URL”)
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:14.679 ServerApp] Package notebook_shim took 0.0000s to import
jupyter-glhong.1.ux8r6lawedie@c3 | [W 2023-04-25 09:00:14.680 ServerApp] A _jupyter_server_extension_points function was not found in notebook_shim. Instead, a _jupyter_server_extension_paths function was found and will be used for now. This function name will be deprecated in future releases of Jupyter Server.
jupyter-glhong.1.ux8r6lawedie@c3 | [D 2023-04-25 09:00:14.688 FileIdExtension] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue {‘update’: {‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.kcr3209r0awy@c3 | Traceback (most recent call last):
jupyter-glhong.1.f6rtu38p7tuf@c3 | KeyError: ‘Missing required environment $JUPYTERHUB_SERVICE_URL’
jupyter-glhong.1.ux8r6lawedie@c3 | [D 2023-04-25 09:00:14.690 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.kcr3209r0awy@c3 | File “/opt/conda/lib/python3.10/site-packages/jupyterhub/singleuser/extension.py”, line 274, in wrapped
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:14.691 ServerApp] jupyter_server_fileid | extension was successfully linked.
jupyter-glhong.1.ux8r6lawedie@c3 | [D 2023-04-25 09:00:14.698 TerminalsExtensionApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.kcr3209r0awy@c3 | r = f(self, *args, **kwargs)
jupyter-glhong.1.ux8r6lawedie@c3 | [D 2023-04-25 09:00:14.700 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:14.701 ServerApp] jupyter_server_terminals | extension was successfully linked.
jupyter-glhong.1.kcr3209r0awy@c3 | File “/opt/conda/lib/python3.10/site-packages/jupyterhub/singleuser/extension.py”, line 472, in load_config_file
jupyter-glhong.1.kcr3209r0awy@c3 | raise KeyError(“Missing required environment $JUPYTERHUB_SERVICE_URL”)
jupyter-glhong.1.ux8r6lawedie@c3 | [D 2023-04-25 09:00:14.708 YDocExtension] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | [D 2023-04-25 09:00:14.710 ServerApp] Config changed: {‘ServerApp’: {‘ip’: ‘0.0.0.0’, ‘port’: 8888, ‘log_level’: ‘DEBUG’, ‘jpserver_extensions’: <LazyConfigValue value={‘jupyterhub’: True, ‘jupyter_server_fileid’: True, ‘jupyter_server_terminals’: True, ‘jupyter_server_ydoc’: True, ‘jupyterlab’: True, ‘nbclassic’: True, ‘notebook_shim’: True}>}, ‘SingleUserNotebookApp’: {‘default_url’: DeferredConfigString(‘/lab’)}, ‘ExtensionApp’: {‘log_level’: ‘DEBUG’}}
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:14.711 ServerApp] jupyter_server_ydoc | extension was successfully linked.
jupyter-glhong.1.kcr3209r0awy@c3 | KeyError: ‘Missing required environment $JUPYTERHUB_SERVICE_URL’
jupyter-glhong.1.ux8r6lawedie@c3 | [I 2023-04-25 09:00:14.711 JupyterHubSingleUser] Starting jupyterhub single-user server extension version 4.0.0
jupyter-glhong.1.ux8r6lawedie@c3 | [E 2023-04-25 09:00:14.712 JupyterHubSingleUser] Failed to load JupyterHubSingleUser server extension
jupyter-glhong.1.m3yxxnpyxwx4@c3 | [I 2023-04-25 09:00:45.239 ServerApp] jupyter_server_ydoc | extension was successfully linked.
jupyter-glhong.1.ux8r6lawedie@c3 | Traceback (most recent call last):
jupyter-glhong.1.ux8r6lawedie@c3 | File “/opt/conda/lib/python3.10/site-packages/jupyterhub/singleuser/extension.py”, line 274, in wrapped
jupyter-glhong.1.ux8r6lawedie@c3 | r = f(self, *args, **kwargs)
jupyter-glhong.1.ux8r6lawedie@c3 | File “/opt/conda/lib/python3.10/site-packages/jupyterhub/singleuser/extension.py”, line 472, in load_config_file
jupyter-glhong.1.ux8r6lawedie@c3 | raise KeyError(“Missing required environment $JUPYTERHUB_SERVICE_URL”)
jupyter-glhong.1.m3yxxnpyxwx4@c3 | [I 2023-04-25 09:00:45.240 JupyterHubSingleUser] Starting jupyterhub single-user server extension version 4.0.0
jupyter-glhong.1.ux8r6lawedie@c3 | KeyError: ‘Missing required environment $JUPYTERHUB_SERVICE_URL’
jupyter-glhong.1.m3yxxnpyxwx4@c3 | [E 2023-04-25 09:00:45.240 JupyterHubSingleUser] Failed to load JupyterHubSingleUser server extension
jupyter-glhong.1.m3yxxnpyxwx4@c3 | Traceback (most recent call last):
jupyter-glhong.1.m3yxxnpyxwx4@c3 | File “/opt/conda/lib/python3.10/site-packages/jupyterhub/singleuser/extension.py”, line 274, in wrapped
jupyter-glhong.1.m3yxxnpyxwx4@c3 | r = f(self, *args, **kwargs)
jupyter-glhong.1.m3yxxnpyxwx4@c3 | File “/opt/conda/lib/python3.10/site-packages/jupyterhub/singleuser/extension.py”, line 472, in load_config_file
jupyter-glhong.1.m3yxxnpyxwx4@c3 | raise KeyError(“Missing required environment $JUPYTERHUB_SERVICE_URL”)
jupyter-glhong.1.m3yxxnpyxwx4@c3 | KeyError: ‘Missing required environment $JUPYTERHUB_SERVICE_URL’

We’ll need more information before we can guess what’s happening. Please could you give us enough information to reproduce your problem? For example if you’re using Docker show us your configuration files, tell us how you’re running everything. Ideally enough information to reproduce your problem from scratch.

I change the base image and it works now, Thanks!

@caiquanyou, which image did you use? I’m having the same issue. I’m trying to run this image jupyter-remote-desktop-proxy/Dockerfile at 2d7eee0e3cc34270931f61f349b0921e9907bcf0 · jupyterhub/jupyter-remote-desktop-proxy · GitHub

From jupyter/minimal:latest

I’m also getting this. Is there a version of the Jupyter/scipy-notebook for python 3.10 that doesn’t have this issue?

I’ve been running into this as well. As a workaround as previously stated, I’ve been going back to older base images.

Seeing same error here. running an older version of jupyterhub,1.2.0 in kubernetes. I even tried rebuilding base-notebook and mininal-notebook from source. error seems to indicate that something in python3.10 jupyterhub.singleuser.extension requires this environment setting. Has a solution been found yet?

Have you tried the latest version of JupyterHub?

The easiest solution to this is to make sure your JupyterHub versions match in both the Hub and the user enviornment. If you see this error, it’s because you started jupyterhub-singleuser 4.0, but the Hub that started it was < 2.0. If you are sticking to jupyterhub 1.x on the Hub, you can run pip install jupyterhub==1.* in the user image to ensure they are close, or pip install jupyterhub==1.x.y to ensure they match exactly (shouldn’t be a requirement, but the easiest way to ensure everything matches).

@minrk Thanks for the info. I got past the error by updating to JupyterHub 2.0.0. All seems to work now. Though, the font used in the “profiles” page seems to have changed drastically.

I am also facing the same issue I am using this nvidia image FROM nvidia/cuda:11.5.1-cudnn8-devel-ubuntu20.04

I still didn’t get the resolution anyone can help me resolving this issue?

The resolution is to make sure the version of the jupyterhub package in both your hub environment and user environment match. Generally, running pip install jupyterhub==$version will do this.