plotly / dash

Data Apps & Dashboards for Python. No JavaScript Required.
https://plotly.com/dash
MIT License
21.47k stars 2.07k forks source link

Jupyter Dash infer_jupyter_config_proxy() running forever #2998

Open Khagesh16 opened 2 months ago

Khagesh16 commented 2 months ago

Thank you so much for helping improve the quality of Dash!

We do our best to catch bugs during the release process, but we rely on your help to find the ones that slip through.

Describe your context

We are hosting jupyterlab on eks cluster with jupyterhub integration for the analytical purposes. In our lab environment we have python kernel with all necessary visualization libs. Dash was working fine previously with separate jupyter-dash installation but now its not working.

Based on the documentation we followed this step

image

Jupyter configuration

IPython          : 8.27.0
ipykernel        : 6.29.5
ipywidgets       : 8.1.5
jupyter_client   : 8.6.2
jupyter_core     : 5.7.2
jupyter_server   : 2.14.2
jupyterlab       : 4.2.5
nbclient         : 0.10.0
nbconvert        : 7.16.4
nbformat         : 5.10.4
notebook         : 7.2.2
qtconsole        : not installed
traitlets        : 5.14.3

Describe the bug

Based on the investigation probably this function is causing the issue.here. I run this code blocked yesterday and its still running in my remote sandbox. As mentioned earlier its hosted on eks pod.

from dash import Dash, html, dcc
import plotly.express as px
import pandas as pd

from dash import jupyter_dash
jupyter_dash.infer_jupyter_proxy_config()

Expected behavior

jupyter_dash.infer_jupyter_proxy_config() should infer the proxy config and let the dash render the plots inline.

Screenshots

image

If applicable, add screenshots or screen recording to help explain your problem.

mthiboust commented 1 month ago

@Khagesh16 : I ran into a similar issue and I made it work by manually changing the dependency constraints of the extension before calling jupyter lab build. See this PR to know what file to change. You can also have a look at this jupyterlab-retrieve-base-url extension as a temporary workaround.