From 165841b9e08427cf3ac7b6805a63278f759b5bed Mon Sep 17 00:00:00 2001 From: Iisakki Rotko Date: Mon, 26 Aug 2024 11:01:02 +0200 Subject: [PATCH] fix: app hangs on starlette when sufficiently many cookies are set In version 13.0 of `websockets`, the environmental variables to configure websockets were renamed (see [here](https://websockets.readthedocs.io/en/stable/project/changelog.html#id2)), which caused apps to hang when running on starlette with more than 8kb of cookies set. --- .../osubuntu-python3.8-ipywidgets7.txt | 230 ----------------- .../osubuntu-python3.8-ipywidgets8.txt | 231 ------------------ .../oswindows-python3.8-ipywidgets7.txt | 228 ----------------- .../oswindows-python3.8-ipywidgets8.txt | 229 ----------------- solara/server/starlette.py | 6 +- 5 files changed, 5 insertions(+), 919 deletions(-) delete mode 100644 .ci-package-locks/integration/osubuntu-python3.8-ipywidgets7.txt delete mode 100644 .ci-package-locks/integration/osubuntu-python3.8-ipywidgets8.txt delete mode 100644 .ci-package-locks/integration/oswindows-python3.8-ipywidgets7.txt delete mode 100644 .ci-package-locks/integration/oswindows-python3.8-ipywidgets8.txt diff --git a/.ci-package-locks/integration/osubuntu-python3.8-ipywidgets7.txt b/.ci-package-locks/integration/osubuntu-python3.8-ipywidgets7.txt deleted file mode 100644 index 255ac26b3..000000000 --- a/.ci-package-locks/integration/osubuntu-python3.8-ipywidgets7.txt +++ /dev/null @@ -1,230 +0,0 @@ -aiofiles==22.1.0 -aiosqlite==0.20.0 -altair==5.4.0 -annotated-types==0.7.0 -anyio==3.7.1 -anywidget==0.9.13 -aplus==0.11.0 -argon2-cffi==23.1.0 -argon2-cffi-bindings==21.2.0 -arrow==1.3.0 -asttokens==2.4.1 -attrs==24.2.0 -Authlib==1.3.1 -babel==2.16.0 -backcall==0.2.0 -beautifulsoup4==4.12.3 -blake3==0.4.1 -bleach==6.1.0 -blinker==1.8.2 -bqplot==0.12.43 -bqplot-image-gl==1.4.11 -branca==0.7.2 -bump2version==1.0.1 -cachetools==5.5.0 -certifi==2024.7.4 -cffi==1.17.0 -cfgv==3.4.0 -charset-normalizer==3.3.2 -click==8.1.7 -cloudpickle==3.0.0 -codespell==2.3.0 -comm==0.2.2 -contourpy==1.1.1 -coverage==7.6.1 -cryptography==43.0.0 -cycler==0.12.1 -dask==2023.5.0 -debugpy==1.8.5 -decorator==5.1.1 -defusedxml==0.7.1 -distlib==0.3.8 -distro==1.9.0 -entrypoints==0.4 -exceptiongroup==1.2.2 -executing==2.0.1 -fastjsonschema==2.20.0 -filelock==3.15.4 -Flask==3.0.3 -flask-sock==0.7.0 -folium==0.17.0 -fonttools==4.53.1 -fqdn==1.5.1 -frozendict==2.4.4 -fsspec==2024.6.1 -future==1.0.0 -greenlet==3.0.3 -h11==0.14.0 -h5py==3.11.0 -httpcore==1.0.5 -httpx==0.27.0 -humanize==4.10.0 -identify==2.6.0 -idna==3.7 -importlib_metadata==8.3.0 -importlib_resources==6.4.3 -iniconfig==2.0.0 -ipycanvas==0.13.2 -ipydatawidgets==4.3.5 -ipykernel==6.29.5 -ipyleaflet==0.19.2 -ipympl==0.9.3 -ipyreact==0.4.1 -ipython==8.12.3 -ipython-genutils==0.2.0 -ipyvolume==0.6.3 -ipyvue==1.11.1 -ipyvuetify==1.10.0 -ipywebrtc==0.6.0 -ipywidgets==7.8.3 -isoduration==20.11.0 -itsdangerous==2.2.0 -jedi==0.19.1 -Jinja2==3.1.4 -jiter==0.5.0 -json5==0.9.25 -jsonpointer==3.0.0 -jsonschema==4.23.0 -jsonschema-specifications==2023.12.1 -jupyter-events==0.10.0 -jupyter-leaflet==0.19.2 -jupyter-server==1.24.0 -jupyter-ydoc==0.2.5 -jupyter_client==7.4.9 -jupyter_core==5.7.2 -jupyter_server_fileid==0.9.2 -jupyter_server_ydoc==0.8.0 -jupyterlab==3.6.7 -jupyterlab_pygments==0.3.0 -jupyterlab_server==2.27.3 -jupyterlab_widgets==1.1.9 -kiwisolver==1.4.5 -locket==1.0.0 -lxml==5.1.1 -Markdown==3.7 -markdown-it-py==3.0.0 -MarkupSafe==2.1.5 -matplotlib==3.7.5 -matplotlib-inline==0.1.7 -mdit-py-plugins==0.4.1 -mdurl==0.1.2 -mistune==0.8.4 -mypy==1.11.1 -mypy-extensions==1.0.0 -narwhals==1.4.2 -nbclassic==1.1.0 -nbclient==0.5.13 -nbconvert==6.5.4 -nbformat==5.10.4 -nest-asyncio==1.6.0 -nodeenv==1.9.1 -notebook==6.5.7 -notebook_shim==0.2.4 -numpy==1.24.4 -openai==1.41.1 -packaging==24.1 -pandas==2.0.3 -pandocfilters==1.5.1 -parso==0.8.4 -partd==1.4.1 -pexpect==4.9.0 -pickleshare==0.7.5 -pillow==10.4.0 -pixelmatch==0.3.0 -pkgutil_resolve_name==1.3.10 -platformdirs==4.2.2 -playwright==1.41.2 -plotly==5.23.0 -pluggy==1.5.0 -polars==1.5.0 -pre-commit==3.5.0 -progressbar2==4.4.2 -prometheus_client==0.20.0 -prompt_toolkit==3.0.47 -psutil==6.0.0 -psygnal==0.11.1 -ptyprocess==0.7.0 -pure_eval==0.2.3 -pyarrow==17.0.0 -pycparser==2.22 -pydantic==1.10.17 -pydantic_core==2.20.1 -pyee==11.0.1 -Pygments==2.18.0 -pymdown-extensions==10.9 -pyparsing==3.1.2 -pytest==8.3.2 -pytest-base-url==2.1.0 -pytest-cov==5.0.0 -pytest-mock==3.14.0 -pytest-playwright==0.5.1 -pytest-timeout==2.3.1 -python-dateutil==2.9.0.post0 -python-dotenv==1.0.1 -python-json-logger==2.0.7 -python-slugify==8.0.4 -python-utils==3.8.2 -pythreejs==2.4.2 -pytz==2024.1 -PyYAML==6.0.2 -pyzmq==26.1.1 -reacton==1.8.3 -referencing==0.35.1 -regex==2024.7.24 -requests==2.32.3 -rfc3339-validator==0.1.4 -rfc3986-validator==0.1.1 -rich==13.7.1 -rich-click==1.8.3 -rpds-py==0.20.0 -ruff==0.6.1 -Send2Trash==1.8.3 -simple-websocket==1.0.0 -six==1.16.0 -sniffio==1.3.1 -soupsieve==2.6 -stack-data==0.6.3 -starlette==0.38.2 -tabulate==0.9.0 -tenacity==9.0.0 -terminado==0.18.1 -text-unidecode==1.3 -tiktoken==0.7.0 -tinycss2==1.3.0 -tomli==2.0.1 -toolz==0.12.1 -tornado==6.4.1 -tqdm==4.66.5 -traitlets==5.14.3 -traittypes==0.2.1 -types-Markdown==3.6.0.20240316 -types-python-dateutil==2.9.0.20240316 -types-PyYAML==6.0.12.20240808 -types-requests==2.32.0.20240712 -typing_extensions==4.12.2 -tzdata==2024.1 -uri-template==1.3.0 -urllib3==2.2.2 -uvicorn==0.30.6 -vaex-core==4.17.1 -vaex-hdf5==0.14.1 -vaex-jupyter==0.8.2 -vaex-viz==0.5.4 -vega-datasets==0.9.0 -virtualenv==20.26.3 -voila==0.3.8 -watchdog==4.0.2 -watchfiles==0.23.0 -wcwidth==0.2.13 -webcolors==24.8.0 -webencodings==0.5.1 -websocket-client==1.8.0 -websockets==12.0 -Werkzeug==3.0.3 -widgetsnbextension==3.6.8 -wsproto==1.2.0 -xarray==2023.1.0 -xyzservices==2024.6.0 -y-py==0.6.2 -ypy-websocket==0.8.4 -zipp==3.20.0 diff --git a/.ci-package-locks/integration/osubuntu-python3.8-ipywidgets8.txt b/.ci-package-locks/integration/osubuntu-python3.8-ipywidgets8.txt deleted file mode 100644 index 2da18fecb..000000000 --- a/.ci-package-locks/integration/osubuntu-python3.8-ipywidgets8.txt +++ /dev/null @@ -1,231 +0,0 @@ -aiofiles==22.1.0 -aiosqlite==0.20.0 -altair==5.4.0 -annotated-types==0.7.0 -anyio==4.4.0 -anywidget==0.9.13 -aplus==0.11.0 -argon2-cffi==23.1.0 -argon2-cffi-bindings==21.2.0 -arrow==1.3.0 -asttokens==2.4.1 -attrs==24.2.0 -Authlib==1.3.1 -babel==2.16.0 -backcall==0.2.0 -beautifulsoup4==4.12.3 -blake3==0.4.1 -bleach==6.1.0 -blinker==1.8.2 -bqplot==0.12.43 -bqplot-image-gl==1.4.11 -branca==0.7.2 -bump2version==1.0.1 -cachetools==5.5.0 -certifi==2024.7.4 -cffi==1.17.0 -cfgv==3.4.0 -charset-normalizer==3.3.2 -click==8.1.7 -cloudpickle==3.0.0 -codespell==2.3.0 -comm==0.2.2 -contourpy==1.1.1 -coverage==7.6.1 -cryptography==43.0.0 -cycler==0.12.1 -dask==2023.5.0 -debugpy==1.8.5 -decorator==5.1.1 -defusedxml==0.7.1 -distlib==0.3.8 -distro==1.9.0 -entrypoints==0.4 -exceptiongroup==1.2.2 -executing==2.0.1 -fastjsonschema==2.20.0 -filelock==3.15.4 -Flask==3.0.3 -flask-sock==0.7.0 -folium==0.17.0 -fonttools==4.53.1 -fqdn==1.5.1 -frozendict==2.4.4 -fsspec==2024.6.1 -future==1.0.0 -greenlet==3.0.3 -h11==0.14.0 -h5py==3.11.0 -httpcore==1.0.5 -httpx==0.27.0 -humanize==4.10.0 -identify==2.6.0 -idna==3.7 -importlib_metadata==8.3.0 -importlib_resources==6.4.3 -iniconfig==2.0.0 -ipycanvas==0.13.2 -ipydatawidgets==4.3.5 -ipykernel==6.29.5 -ipyleaflet==0.19.2 -ipympl==0.9.3 -ipyreact==0.4.1 -ipython==8.12.3 -ipython-genutils==0.2.0 -ipyvolume==0.6.3 -ipyvue==1.11.1 -ipyvuetify==1.10.0 -ipywebrtc==0.6.0 -ipywidgets==8.1.3 -isoduration==20.11.0 -itsdangerous==2.2.0 -jedi==0.19.1 -Jinja2==3.1.4 -jiter==0.5.0 -json5==0.9.25 -jsonpointer==3.0.0 -jsonschema==4.23.0 -jsonschema-specifications==2023.12.1 -jupyter-events==0.10.0 -jupyter-leaflet==0.19.2 -jupyter-ydoc==0.2.5 -jupyter_client==7.4.9 -jupyter_core==5.7.2 -jupyter_server==2.14.2 -jupyter_server_fileid==0.9.2 -jupyter_server_terminals==0.5.3 -jupyter_server_ydoc==0.8.0 -jupyterlab==3.6.7 -jupyterlab_pygments==0.3.0 -jupyterlab_server==2.27.3 -jupyterlab_widgets==3.0.11 -kiwisolver==1.4.5 -locket==1.0.0 -Markdown==3.7 -markdown-it-py==3.0.0 -MarkupSafe==2.1.5 -matplotlib==3.7.5 -matplotlib-inline==0.1.7 -mdit-py-plugins==0.4.1 -mdurl==0.1.2 -mistune==3.0.2 -mypy==1.11.1 -mypy-extensions==1.0.0 -narwhals==1.4.2 -nbclassic==1.1.0 -nbclient==0.10.0 -nbconvert==7.16.4 -nbformat==5.10.4 -nest-asyncio==1.6.0 -nodeenv==1.9.1 -notebook==6.5.7 -notebook_shim==0.2.4 -numpy==1.24.4 -openai==1.41.1 -overrides==7.7.0 -packaging==24.1 -pandas==2.0.3 -pandocfilters==1.5.1 -parso==0.8.4 -partd==1.4.1 -pexpect==4.9.0 -pickleshare==0.7.5 -pillow==10.4.0 -pixelmatch==0.3.0 -pkgutil_resolve_name==1.3.10 -platformdirs==4.2.2 -playwright==1.41.2 -plotly==5.23.0 -pluggy==1.5.0 -polars==1.5.0 -pre-commit==3.5.0 -progressbar2==4.4.2 -prometheus_client==0.20.0 -prompt_toolkit==3.0.47 -psutil==6.0.0 -psygnal==0.11.1 -ptyprocess==0.7.0 -pure_eval==0.2.3 -pyarrow==17.0.0 -pycparser==2.22 -pydantic==1.10.17 -pydantic_core==2.20.1 -pyee==11.0.1 -Pygments==2.18.0 -pymdown-extensions==10.9 -pyparsing==3.1.2 -pytest==8.3.2 -pytest-base-url==2.1.0 -pytest-cov==5.0.0 -pytest-mock==3.14.0 -pytest-playwright==0.5.1 -pytest-timeout==2.3.1 -python-dateutil==2.9.0.post0 -python-dotenv==1.0.1 -python-json-logger==2.0.7 -python-slugify==8.0.4 -python-utils==3.8.2 -pythreejs==2.4.2 -pytz==2024.1 -PyYAML==6.0.2 -pyzmq==26.1.1 -reacton==1.8.3 -referencing==0.35.1 -regex==2024.7.24 -requests==2.32.3 -rfc3339-validator==0.1.4 -rfc3986-validator==0.1.1 -rich==13.7.1 -rich-click==1.8.3 -rpds-py==0.20.0 -ruff==0.6.1 -Send2Trash==1.8.3 -simple-websocket==1.0.0 -six==1.16.0 -sniffio==1.3.1 -soupsieve==2.6 -stack-data==0.6.3 -starlette==0.38.2 -tabulate==0.9.0 -tenacity==9.0.0 -terminado==0.18.1 -text-unidecode==1.3 -tiktoken==0.7.0 -tinycss2==1.3.0 -tomli==2.0.1 -toolz==0.12.1 -tornado==6.4.1 -tqdm==4.66.5 -traitlets==5.14.3 -traittypes==0.2.1 -types-Markdown==3.6.0.20240316 -types-python-dateutil==2.9.0.20240316 -types-PyYAML==6.0.12.20240808 -types-requests==2.32.0.20240712 -typing_extensions==4.12.2 -tzdata==2024.1 -uri-template==1.3.0 -urllib3==2.2.2 -uvicorn==0.30.6 -vaex-core==4.17.1 -vaex-hdf5==0.14.1 -vaex-jupyter==0.8.2 -vaex-viz==0.5.4 -vega-datasets==0.9.0 -virtualenv==20.26.3 -voila==0.5.7 -watchdog==4.0.2 -watchfiles==0.23.0 -wcwidth==0.2.13 -webcolors==24.8.0 -webencodings==0.5.1 -websocket-client==1.8.0 -websockets==12.0 -Werkzeug==3.0.3 -widgetsnbextension==4.0.11 -wsproto==1.2.0 -xarray==2023.1.0 -xyzservices==2024.6.0 -y-py==0.6.2 -ypy-websocket==0.8.4 -zipp==3.20.0 diff --git a/.ci-package-locks/integration/oswindows-python3.8-ipywidgets7.txt b/.ci-package-locks/integration/oswindows-python3.8-ipywidgets7.txt deleted file mode 100644 index 7671189d5..000000000 --- a/.ci-package-locks/integration/oswindows-python3.8-ipywidgets7.txt +++ /dev/null @@ -1,228 +0,0 @@ -aiofiles==22.1.0 -aiosqlite==0.20.0 -altair==5.3.0 -annotated-types==0.7.0 -anyio==3.7.1 -anywidget==0.9.13 -aplus==0.11.0 -argon2-cffi==23.1.0 -argon2-cffi-bindings==21.2.0 -arrow==1.3.0 -asttokens==2.4.1 -attrs==23.2.0 -Authlib==1.3.1 -Babel==2.15.0 -backcall==0.2.0 -beautifulsoup4==4.12.3 -blake3==0.4.1 -bleach==6.1.0 -blinker==1.8.2 -bqplot==0.12.43 -bqplot-image-gl==1.4.11 -branca==0.7.2 -bump2version==1.0.1 -cachetools==5.3.3 -certifi==2024.7.4 -cffi==1.16.0 -cfgv==3.4.0 -charset-normalizer==3.3.2 -click==8.1.7 -cloudpickle==3.0.0 -codespell==2.3.0 -comm==0.2.2 -contourpy==1.1.1 -coverage==7.5.4 -cryptography==42.0.8 -cycler==0.12.1 -dask==2023.5.0 -debugpy==1.8.2 -decorator==5.1.1 -defusedxml==0.7.1 -distlib==0.3.8 -distro==1.9.0 -entrypoints==0.4 -exceptiongroup==1.2.1 -executing==2.0.1 -fastjsonschema==2.20.0 -filelock==3.15.4 -Flask==3.0.3 -flask-sock==0.7.0 -folium==0.17.0 -fonttools==4.53.1 -fqdn==1.5.1 -frozendict==2.4.4 -fsspec==2024.6.1 -future==1.0.0 -greenlet==3.0.3 -h11==0.14.0 -h5py==3.11.0 -httpcore==1.0.5 -httpx==0.27.0 -humanize==4.10.0 -identify==2.6.0 -idna==3.7 -importlib_metadata==8.0.0 -importlib_resources==6.4.0 -iniconfig==2.0.0 -ipycanvas==0.13.2 -ipydatawidgets==4.3.5 -ipykernel==6.29.5 -ipyleaflet==0.19.1 -ipympl==0.9.3 -ipyreact==0.4.1 -ipython==8.12.3 -ipython-genutils==0.2.0 -ipyvolume==0.6.3 -ipyvue==1.11.1 -ipyvuetify==1.9.4 -ipywebrtc==0.6.0 -ipywidgets==7.8.2 -isoduration==20.11.0 -itsdangerous==2.2.0 -jedi==0.19.1 -Jinja2==3.1.4 -json5==0.9.25 -jsonpointer==3.0.0 -jsonschema==4.23.0 -jsonschema-specifications==2023.12.1 -jupyter-events==0.10.0 -jupyter-leaflet==0.19.1 -jupyter-server==1.24.0 -jupyter-ydoc==0.2.5 -jupyter_client==7.4.9 -jupyter_core==5.7.2 -jupyter_server_fileid==0.9.2 -jupyter_server_ydoc==0.8.0 -jupyterlab==3.6.7 -jupyterlab_pygments==0.3.0 -jupyterlab_server==2.27.2 -jupyterlab_widgets==1.1.8 -kiwisolver==1.4.5 -locket==1.0.0 -lxml==5.1.1 -Markdown==3.6 -markdown-it-py==3.0.0 -MarkupSafe==2.1.5 -matplotlib==3.7.5 -matplotlib-inline==0.1.7 -mdit-py-plugins==0.4.1 -mdurl==0.1.2 -mistune==0.8.4 -mypy==1.10.1 -mypy-extensions==1.0.0 -nbclassic==1.1.0 -nbclient==0.5.13 -nbconvert==6.5.4 -nbformat==5.10.4 -nest-asyncio==1.6.0 -nodeenv==1.9.1 -notebook==6.5.7 -notebook_shim==0.2.4 -numpy==1.24.4 -openai==1.35.13 -packaging==24.1 -pandas==2.0.3 -pandocfilters==1.5.1 -parso==0.8.4 -partd==1.4.1 -pexpect==4.9.0 -pickleshare==0.7.5 -pillow==10.4.0 -pixelmatch==0.3.0 -pkgutil_resolve_name==1.3.10 -platformdirs==4.2.2 -playwright==1.41.2 -plotly==5.22.0 -pluggy==1.5.0 -polars==1.1.0 -pre-commit==3.5.0 -progressbar2==4.4.2 -prometheus_client==0.20.0 -prompt_toolkit==3.0.47 -psutil==6.0.0 -psygnal==0.11.1 -ptyprocess==0.7.0 -pure-eval==0.2.2 -pyarrow==16.1.0 -pycparser==2.22 -pydantic==1.10.17 -pydantic_core==2.20.1 -pyee==11.0.1 -Pygments==2.18.0 -pymdown-extensions==10.8.1 -pyparsing==3.1.2 -pytest==8.2.2 -pytest-base-url==2.1.0 -pytest-cov==5.0.0 -pytest-mock==3.14.0 -pytest-playwright==0.5.1 -pytest-timeout==2.3.1 -python-dateutil==2.9.0.post0 -python-dotenv==1.0.1 -python-json-logger==2.0.7 -python-slugify==8.0.4 -python-utils==3.8.2 -pythreejs==2.4.2 -pytz==2024.1 -PyYAML==6.0.1 -pyzmq==26.0.3 -reacton==1.8.3 -referencing==0.35.1 -regex==2024.5.15 -requests==2.32.3 -rfc3339-validator==0.1.4 -rfc3986-validator==0.1.1 -rich==13.7.1 -rich-click==1.8.3 -rpds-py==0.19.0 -ruff==0.5.1 -Send2Trash==1.8.3 -simple-websocket==1.0.0 -six==1.16.0 -sniffio==1.3.1 -soupsieve==2.5 -stack-data==0.6.3 -starlette==0.37.2 -tabulate==0.9.0 -tenacity==8.5.0 -terminado==0.18.1 -text-unidecode==1.3 -tiktoken==0.7.0 -tinycss2==1.3.0 -tomli==2.0.1 -toolz==0.12.1 -tornado==6.4.1 -tqdm==4.66.4 -traitlets==5.14.3 -traittypes==0.2.1 -types-Markdown==3.6.0.20240316 -types-python-dateutil==2.9.0.20240316 -types-PyYAML==6.0.12.20240311 -types-requests==2.32.0.20240622 -typing_extensions==4.12.2 -tzdata==2024.1 -uri-template==1.3.0 -urllib3==2.2.2 -uvicorn==0.30.1 -vaex-core==4.17.1 -vaex-hdf5==0.14.1 -vaex-jupyter==0.8.2 -vaex-viz==0.5.4 -vega-datasets==0.9.0 -virtualenv==20.26.3 -voila==0.3.8 -watchdog==4.0.1 -watchfiles==0.22.0 -wcwidth==0.2.13 -webcolors==24.6.0 -webencodings==0.5.1 -websocket-client==1.8.0 -websockets==12.0 -Werkzeug==3.0.3 -widgetsnbextension==3.6.7 -wsproto==1.2.0 -xarray==2023.1.0 -xyzservices==2024.6.0 -y-py==0.6.2 -ypy-websocket==0.8.4 -zipp==3.19.2 diff --git a/.ci-package-locks/integration/oswindows-python3.8-ipywidgets8.txt b/.ci-package-locks/integration/oswindows-python3.8-ipywidgets8.txt deleted file mode 100644 index 89ede43e4..000000000 --- a/.ci-package-locks/integration/oswindows-python3.8-ipywidgets8.txt +++ /dev/null @@ -1,229 +0,0 @@ -aiofiles==22.1.0 -aiosqlite==0.20.0 -altair==5.3.0 -annotated-types==0.7.0 -anyio==4.4.0 -anywidget==0.9.13 -aplus==0.11.0 -argon2-cffi==23.1.0 -argon2-cffi-bindings==21.2.0 -arrow==1.3.0 -asttokens==2.4.1 -attrs==23.2.0 -Authlib==1.3.1 -Babel==2.15.0 -backcall==0.2.0 -beautifulsoup4==4.12.3 -blake3==0.4.1 -bleach==6.1.0 -blinker==1.8.2 -bqplot==0.12.43 -bqplot-image-gl==1.4.11 -branca==0.7.2 -bump2version==1.0.1 -cachetools==5.3.3 -certifi==2024.7.4 -cffi==1.16.0 -cfgv==3.4.0 -charset-normalizer==3.3.2 -click==8.1.7 -cloudpickle==3.0.0 -codespell==2.3.0 -comm==0.2.2 -contourpy==1.1.1 -coverage==7.5.4 -cryptography==42.0.8 -cycler==0.12.1 -dask==2023.5.0 -debugpy==1.8.2 -decorator==5.1.1 -defusedxml==0.7.1 -distlib==0.3.8 -distro==1.9.0 -entrypoints==0.4 -exceptiongroup==1.2.1 -executing==2.0.1 -fastjsonschema==2.20.0 -filelock==3.15.4 -Flask==3.0.3 -flask-sock==0.7.0 -folium==0.17.0 -fonttools==4.53.1 -fqdn==1.5.1 -frozendict==2.4.4 -fsspec==2024.6.1 -future==1.0.0 -greenlet==3.0.3 -h11==0.14.0 -h5py==3.11.0 -httpcore==1.0.5 -httpx==0.27.0 -humanize==4.10.0 -identify==2.6.0 -idna==3.7 -importlib_metadata==8.0.0 -importlib_resources==6.4.0 -iniconfig==2.0.0 -ipycanvas==0.13.2 -ipydatawidgets==4.3.5 -ipykernel==6.29.5 -ipyleaflet==0.19.1 -ipympl==0.9.3 -ipyreact==0.4.1 -ipython==8.12.3 -ipython-genutils==0.2.0 -ipyvolume==0.6.3 -ipyvue==1.11.1 -ipyvuetify==1.9.4 -ipywebrtc==0.6.0 -ipywidgets==8.1.3 -isoduration==20.11.0 -itsdangerous==2.2.0 -jedi==0.19.1 -Jinja2==3.1.4 -json5==0.9.25 -jsonpointer==3.0.0 -jsonschema==4.23.0 -jsonschema-specifications==2023.12.1 -jupyter-events==0.10.0 -jupyter-leaflet==0.19.1 -jupyter-ydoc==0.2.5 -jupyter_client==7.4.9 -jupyter_core==5.7.2 -jupyter_server==2.14.1 -jupyter_server_fileid==0.9.2 -jupyter_server_terminals==0.5.3 -jupyter_server_ydoc==0.8.0 -jupyterlab==3.6.7 -jupyterlab_pygments==0.3.0 -jupyterlab_server==2.27.2 -jupyterlab_widgets==3.0.11 -kiwisolver==1.4.5 -locket==1.0.0 -Markdown==3.6 -markdown-it-py==3.0.0 -MarkupSafe==2.1.5 -matplotlib==3.7.5 -matplotlib-inline==0.1.7 -mdit-py-plugins==0.4.1 -mdurl==0.1.2 -mistune==3.0.2 -mypy==1.10.1 -mypy-extensions==1.0.0 -nbclassic==1.1.0 -nbclient==0.10.0 -nbconvert==7.16.4 -nbformat==5.10.4 -nest-asyncio==1.6.0 -nodeenv==1.9.1 -notebook==6.5.7 -notebook_shim==0.2.4 -numpy==1.24.4 -openai==1.35.13 -overrides==7.7.0 -packaging==24.1 -pandas==2.0.3 -pandocfilters==1.5.1 -parso==0.8.4 -partd==1.4.1 -pexpect==4.9.0 -pickleshare==0.7.5 -pillow==10.4.0 -pixelmatch==0.3.0 -pkgutil_resolve_name==1.3.10 -platformdirs==4.2.2 -playwright==1.41.2 -plotly==5.22.0 -pluggy==1.5.0 -polars==1.1.0 -pre-commit==3.5.0 -progressbar2==4.4.2 -prometheus_client==0.20.0 -prompt_toolkit==3.0.47 -psutil==6.0.0 -psygnal==0.11.1 -ptyprocess==0.7.0 -pure-eval==0.2.2 -pyarrow==16.1.0 -pycparser==2.22 -pydantic==1.10.17 -pydantic_core==2.20.1 -pyee==11.0.1 -Pygments==2.18.0 -pymdown-extensions==10.8.1 -pyparsing==3.1.2 -pytest==8.2.2 -pytest-base-url==2.1.0 -pytest-cov==5.0.0 -pytest-mock==3.14.0 -pytest-playwright==0.5.1 -pytest-timeout==2.3.1 -python-dateutil==2.9.0.post0 -python-dotenv==1.0.1 -python-json-logger==2.0.7 -python-slugify==8.0.4 -python-utils==3.8.2 -pythreejs==2.4.2 -pytz==2024.1 -PyYAML==6.0.1 -pyzmq==26.0.3 -reacton==1.8.3 -referencing==0.35.1 -regex==2024.5.15 -requests==2.32.3 -rfc3339-validator==0.1.4 -rfc3986-validator==0.1.1 -rich==13.7.1 -rich-click==1.8.3 -rpds-py==0.19.0 -ruff==0.5.1 -Send2Trash==1.8.3 -simple-websocket==1.0.0 -six==1.16.0 -sniffio==1.3.1 -soupsieve==2.5 -stack-data==0.6.3 -starlette==0.37.2 -tabulate==0.9.0 -tenacity==8.5.0 -terminado==0.18.1 -text-unidecode==1.3 -tiktoken==0.7.0 -tinycss2==1.3.0 -tomli==2.0.1 -toolz==0.12.1 -tornado==6.4.1 -tqdm==4.66.4 -traitlets==5.14.3 -traittypes==0.2.1 -types-Markdown==3.6.0.20240316 -types-python-dateutil==2.9.0.20240316 -types-PyYAML==6.0.12.20240311 -types-requests==2.32.0.20240622 -typing_extensions==4.12.2 -tzdata==2024.1 -uri-template==1.3.0 -urllib3==2.2.2 -uvicorn==0.30.1 -vaex-core==4.17.1 -vaex-hdf5==0.14.1 -vaex-jupyter==0.8.2 -vaex-viz==0.5.4 -vega-datasets==0.9.0 -virtualenv==20.26.3 -voila==0.5.7 -watchdog==4.0.1 -watchfiles==0.22.0 -wcwidth==0.2.13 -webcolors==24.6.0 -webencodings==0.5.1 -websocket-client==1.8.0 -websockets==12.0 -Werkzeug==3.0.3 -widgetsnbextension==4.0.11 -wsproto==1.2.0 -xarray==2023.1.0 -xyzservices==2024.6.0 -y-py==0.6.2 -ypy-websocket==0.8.4 -zipp==3.19.2 diff --git a/solara/server/starlette.py b/solara/server/starlette.py index 062271a61..3e375ccc6 100644 --- a/solara/server/starlette.py +++ b/solara/server/starlette.py @@ -85,7 +85,11 @@ def _ensure_limiter(): # Since starlette seems to accept really large values for http, lets do the same for websockets # An arbitrarily large value we settled on for now is 32kb # If we don't do this, users with many cookies will fail to get a websocket connection. -websockets.legacy.http.MAX_LINE = 1024 * 32 +ws_version = tuple(map(int, websockets.__version__.split("."))) +if ws_version[0] >= 13: + websockets.legacy.http.MAX_LINE_LENGTH = int(os.environ.get("WEBSOCKETS_MAX_LINE_LENGTH", str(1024 * 32))) # type: ignore +else: + websockets.legacy.http.MAX_LINE = 1024 * 32 # type: ignore class WebsocketDebugInfo: