Panel preview not working

The preview tab is empty (even for the miminum-set example) as shown following:

Animation

$ jupyter --version
Selected Jupyter core packages...
IPython          : 7.31.1
ipykernel        : 6.15.2
ipywidgets       : 7.6.5
jupyter_client   : 7.3.4
jupyter_core     : 4.11.1
jupyter_server   : 1.18.1
jupyterlab       : 3.4.4
nbclient         : 0.5.13
nbconvert        : 6.4.4
nbformat         : 5.5.0
notebook         : 6.4.12
qtconsole        : 5.2.2
traitlets        : 5.1.1

$ jupyter serverextension list
    - Validating...
      panel.io.jupyter_server_extension  ok
    - Validating...
      jupyter_resource_usage 0.7.1 ok
    - Validating...
      jupyterlab 3.4.4 ok
    - Validating...
      panel.io.jupyter_server_extension  ok
config dir: <some_path>\.jupyter
    panel.io.jupyter_server_extension enabled
config dir: <some_other_path>\etc\jupyter
    jupyter_resource_usage enabled
    jupyterlab enabled
    panel.io.jupyter_server_extension enabled

$ conda list panel
# Name                    Version                   Build  Channel
panel                     0.14.3           py39haa95532_0

The kernel I chose for the jupyter-lab is the same virtual environment that I executed the above code.
The return of “conda list jupyter-panel-proxy” is empty for me though (no such package found and no such package can be installed )

At the same time, I do see alarming warning messages after I press F12 (of chrome):

consumes:40 Unsatisfied version 3.4.4 of shared singleton module @jupyterlab/notebook (required ^3.6.0-beta.0)
getSingletonVersion @ consumes:40
consumes:40 Unsatisfied version 3.4.4 of shared singleton module @jupyterlab/settingregistry (required ^3.6.0-beta.0)
getSingletonVersion @ consumes:40
remoteEntry.152ba1289827b31fd2fb.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/statusbar (required ^3.6.1)
s @ remoteEntry.152ba1289827b31fd2fb.js:1
remoteEntry.152ba1289827b31fd2fb.js:1 Unsatisfied version 6.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/services (required ^6.6.1)
s @ remoteEntry.152ba1289827b31fd2fb.js:1
remoteEntry.152ba1289827b31fd2fb.js:1 Unsatisfied version 1.33.0 from @jupyterlab/application-top of shared singleton module @lumino/widgets (required ^1.37.1)
s @ remoteEntry.152ba1289827b31fd2fb.js:1
remoteEntry.152ba1289827b31fd2fb.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/translation (required ^3.6.1)
s @ remoteEntry.152ba1289827b31fd2fb.js:1
remoteEntry.152ba1289827b31fd2fb.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/apputils (required ^3.6.1)
s @ remoteEntry.152ba1289827b31fd2fb.js:1
remoteEntry.152ba1289827b31fd2fb.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/ui-components (required ^3.6.1)
s @ remoteEntry.152ba1289827b31fd2fb.js:1
remoteEntry.152ba1289827b31fd2fb.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/notebook (required ^3.6.1)
s @ remoteEntry.152ba1289827b31fd2fb.js:1
remoteEntry.152ba1289827b31fd2fb.js:1 Unsatisfied version 5.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/coreutils (required ^5.6.1)
s @ remoteEntry.152ba1289827b31fd2fb.js:1
remoteEntry.d748278d6fcf6c58bf94.js:1 Unsatisfied version 5.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/coreutils (required ^5.4.5)
f @ remoteEntry.d748278d6fcf6c58bf94.js:1
remoteEntry.d748278d6fcf6c58bf94.js:1 No satisfying version (^3.4.5) of shared module @jupyterlab/docregistry found in shared scope default.
Available versions: 3.4.4 from @jupyterlab/application-top
c @ remoteEntry.d748278d6fcf6c58bf94.js:1
remoteEntry.d748278d6fcf6c58bf94.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/mainmenu (required ^3.4.5)
f @ remoteEntry.d748278d6fcf6c58bf94.js:1
remoteEntry.d748278d6fcf6c58bf94.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/docmanager (required ^3.4.5)
f @ remoteEntry.d748278d6fcf6c58bf94.js:1
remoteEntry.d748278d6fcf6c58bf94.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/application (required ^3.4.5)
f @ remoteEntry.d748278d6fcf6c58bf94.js:1
remoteEntry.d748278d6fcf6c58bf94.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/ui-components (required ^3.4.5)
f @ remoteEntry.d748278d6fcf6c58bf94.js:1
remoteEntry.d748278d6fcf6c58bf94.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/settingregistry (required ^3.4.5)
f @ remoteEntry.d748278d6fcf6c58bf94.js:1
remoteEntry.d748278d6fcf6c58bf94.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/notebook (required ^3.4.5)
f @ remoteEntry.d748278d6fcf6c58bf94.js:1
remoteEntry.d748278d6fcf6c58bf94.js:1 Unsatisfied version 3.4.4 from @jupyterlab/application-top of shared singleton module @jupyterlab/apputils (required ^3.4.5)
f @ remoteEntry.d748278d6fcf6c58bf94.js:1
DevTools failed to load source map: Could not load content for chrome-extension://cfhdojbkjhnklbpkdaibdccddilifddb/browser-polyfill.js.map: System error: net::ERR_FILE_NOT_FOUND
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/main.c047a5cb14c1d595046d.js.map?v=c047a5cb14c1d595046d: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/9473.5a9c6a963b6aaa178bc3.js.map?v=5a9c6a963b6aaa178bc3: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/6700.7d1bee36bbdf64ab0bd4.js.map?v=7d1bee36bbdf64ab0bd4: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/2719.1001d896f21f09c3f99f.js.map?v=1001d896f21f09c3f99f: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/1036.e3242066e92a791822b6.js.map?v=e3242066e92a791822b6: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/1033.890eeae47460e241b1e9.js.map?v=890eeae47460e241b1e9: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/4155.784ca1752696680bf373.js.map?v=784ca1752696680bf373: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/4570.53adcb6f69939da383ff.js.map?v=53adcb6f69939da383ff: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/7294.f71c2889fedcd71bd1ee.js.map?v=f71c2889fedcd71bd1ee: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/3935.4159b022aa6d82e44127.js.map?v=4159b022aa6d82e44127: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/5096.96faf5ddac346a9ad9c3.js.map?v=96faf5ddac346a9ad9c3: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/1142.074d125bb59f5a332666.js.map?v=074d125bb59f5a332666: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/3308.3a94151c0d57440646ab.js.map?v=3a94151c0d57440646ab: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/7755.d506a1d9dadf30b1e490.js.map?v=d506a1d9dadf30b1e490: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/807.96166378e2efe232d81e.js.map?v=96166378e2efe232d81e: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/4631.96a143e70f005fef7b59.js.map?v=96a143e70f005fef7b59: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/2040.6489997c35a5d7b0b100.js.map?v=6489997c35a5d7b0b100: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/3029.8636761a48c8422ce37f.js.map?v=8636761a48c8422ce37f: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/1287.0e48071eeb17a3bea8e5.js.map?v=0e48071eeb17a3bea8e5: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/1057.a0608544097dd22a589e.js.map?v=a0608544097dd22a589e: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/3502.c915d993b864739407e3.js.map?v=c915d993b864739407e3: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/6080.39703b8cc7bd284ce1bd.js.map?v=39703b8cc7bd284ce1bd: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/jlab_core.081dc2b13065c79d8463.js.map?v=081dc2b13065c79d8463: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/4151.fd7ca59b64f0adc97032.js.map?v=fd7ca59b64f0adc97032: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/3496.ecb0e7fcc54191234ae6.js.map?v=ecb0e7fcc54191234ae6: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/911.0c08f040896753efc653.js.map?v=0c08f040896753efc653: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/126.1e2fb998804b27c72a3e.js.map?v=1e2fb998804b27c72a3e: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/1358.9ab4f57e8227ce75f427.js.map?v=9ab4f57e8227ce75f427: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/1249.047c76b5ea96a41605db.js.map?v=047c76b5ea96a41605db: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/4429.c4f083ef6b6e29345fd4.js.map?v=c4f083ef6b6e29345fd4: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/7796.a62f2ce2891c993a18e5.js.map?v=a62f2ce2891c993a18e5: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for http://localhost:8889/static/lab/714.a8445b6bf08d4979bfe3.js.map?v=a8445b6bf08d4979bfe3: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE

Animation

Message in the terminal (Windows) that launched jupyterlab:

[W 2023-02-28 14:11:43.580 ServerApp] Got events for closed stream <zmq.eventloop.zmqstream.ZMQStream object at 0x0000019EE1005040>
[E 2023-02-28 14:11:54.522 ServerApp] Uncaught exception GET /panel/ (::1)
    HTTPServerRequest(protocol='http', host='localhost:8891', method='GET', uri='/panel/', version='HTTP/1.1', remote_ip='::1')
    Traceback (most recent call last):
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\site-packages\tornado\web.py", line 1704, in _execute
        result = await result
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\site-packages\jupyter_server_proxy\websocket.py", line 91, in get
        return await self.http_get(*args, **kwargs)
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\site-packages\jupyter_server_proxy\handlers.py", line 683, in http_get
        return await ensure_async(self.proxy(self.port, path))
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\site-packages\jupyter_server\utils.py", line 182, in ensure_async
        result = await obj
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\site-packages\jupyter_server_proxy\handlers.py", line 677, in proxy
        await self.ensure_process()
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\site-packages\jupyter_server_proxy\handlers.py", line 654, in ensure_process
        await proc.start()
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\site-packages\simpervisor\process.py", line 90, in start
        self.proc = await asyncio.create_subprocess_exec(
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\asyncio\subprocess.py", line 236, in create_subprocess_exec
        transport, protocol = await loop.subprocess_exec(
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\asyncio\base_events.py", line 1676, in subprocess_exec
        transport = await self._make_subprocess_transport(
      File "C:\ProgramData\Anaconda3\envs\env_panel\lib\asyncio\base_events.py", line 498, in _make_subprocess_transport
        raise NotImplementedError
    NotImplementedError
[E 2023-02-28 14:11:54.526 ServerApp] {
      "Host": "localhost:8891",
      "Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7",
      "Referer": "http://localhost:8891/lab",
      "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/110.0.0.0 Safari/537.36"
    }

Hi @AutFirst

The root cause of your problem can be many, many things.

I would recommend trying to create a new minimal conda environment with panel and jupyterlab installed. Base the environment on a recent version of Python like 3.9 or 3.10.

Then start jupyter lab from the environment.

Then create a notebook with the two cells

import panel as pn
pn.extension()
pn.panel("hello").servable()
  • If that does not work, then report back.
  • If that works you can try additionally installing your packages and try running your full notebook. If the full notebook does not work, then try to remove cells until it works.