Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: cannot import name 'SessionInfo' from 'streamlit.web.server.server' #1024

Closed
AmmarAhmedAlvi opened this issue Aug 26, 2022 · 3 comments · Fixed by #1026
Closed

Comments

@AmmarAhmedAlvi
Copy link

I am using ngrok to connect to virtual server environment and run into this error

This import error occurs since the last update. And I am able to solve it by downgrading streamlit to 1.11.0

Complete log:

File "/usr/local/lib/python3.7/dist-packages/streamlit/runtime/scriptrunner/script_runner.py", line 556, in _run_script
exec(code, module.dict)
File "/content/streamlit_app.py", line 2, in
from streamlit_webrtc import webrtc_streamer
File "/usr/local/lib/python3.7/dist-packages/streamlit_webrtc/init.py", line 10, in
from .component import (
File "/usr/local/lib/python3.7/dist-packages/streamlit_webrtc/component.py", line 47, in
from .session_info import get_script_run_count, get_this_session_info
File "/usr/local/lib/python3.7/dist-packages/streamlit_webrtc/session_info.py", line 4, in
from streamlit.web.server.server import SessionInfo

@whitphx
Copy link
Owner

whitphx commented Aug 26, 2022

Thank you for the report.

It seems that this problem has occurred since streamlit==1.12.1

I will fix it.


Technical note:

The change has been introduced in this PR:
https://github.com/streamlit/streamlit/pull/5136/files#diff-3f73cf34a1595773b3b79ea85c5efd0c208e23beec4f812fa05419f87cff597e

@AmmarAhmedAlvi
Copy link
Author

Thank you for the quick fix whitphx 👍

@whitphx
Copy link
Owner

whitphx commented Aug 26, 2022

It should be fixed with streamlit-webrtc==0.43.1, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants