Built-in charts (e.g. st.line_chart) get a brand-new look and parameters x and y! Check out our blog post for more information.
Notable Changes
Functions cached with st.experimental_memo or st.experimental_singleton can now contain static st commands. This allows caching text, charts, dataframes, and more!
↔️ The sidebar is now resizable via drag and drop.
st.info, st.success, st.error, and st.warning got a redesign and have a new keyword-only parameter: icon.
Other Changes
st.select_slider correctly handles all floats now (#4973, #4978).
st.multi_select can take values from enums (#4987).
st.slider range values can now be set through st.session_state (#5007).
Hi @jrieke, I upgraded Streamlit from 1.11.0 to 1.12.0.
In my Streamlit application I had a sidebar with a st.radio with many elements. 1.11.0 had a scrollbar, whereas 1.12.0 didn’t have a scrollbar, so I couldn’t get to the elements beyond the bottom of the page. I reverted to 1.11.0 and everything was fine.
@Shawn_Pereira Does the scrollbar not show up for you at all? Can you make a small video by any chance? And which browser are you using?
I realized we made a little bug where you cannot actually click the scrollbar (related to the user-resizable sidebar). Filed an issue here. I’ll make sure we fix that. But it should still show up at least (and it does for me!).
If the sidebar is reduced too much, the scrollbar appears a distance away to the right (where you don’t expect it to be), and therefore think there is no scrollbar.
If the sidebar is increased too much, the opposite happens. Again, you will have to move your mouse horizontally to find the scrollbar (as it does not stick to the edge of the sidebar, as one would expect it to, otherwise the scrollbar doesn’t appear)
If the position of the sidebar-width-change drag handles coincide with the internal scrollbar position (where the scrollbar is supposed to appear), no scrollbar is displayed at all until the sidebar width is changed (because they probably overlap). This, I suspect, is what happened when I tried 1.12.0 out.
In the applications I write (using Streamlit), there is never a reason for the end user of the application to adjust the sidebar. I therefore suggest a new alternative command… say st.sidebarwidth(width = ?), which one can use to create different sidebar widths for each page depending on the content of that page.
I support this idea. So far I have been doing this by injecting some CSS. But having this option as a built-in function alongside a boolean switch to generally turn the resizable sidebar on/off for the entire app (be it through a parameter passed to a streamlit function call or some configuration file) would be the best solution.
@Shawn_Pereira Hmm ok that is indeed a bug. I’m on vacation right now, so can’t look into it for the next 2 weeks. Could you open an issue on Github and copy your text/screenshots in there? Then we have it tracked and the engineers can look into it. Fyi @mayabarnes for visibility.
I upgraded Streamlit from 1.11.0 to 1.12.0 on my office server. When I tried to run Streamlit, I got the following error:
Traceback (most recent call last):
File "C:\Program Files\Python39\lib\runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Program Files\Python39\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "C:\Program Files\Python39\Scripts\streamlit.exe\__main__.py", line 4, in <module>
ModuleNotFoundError: No module named 'streamlit.cli'
As per online help, I even tried ‘pip install networkx’ but nothing worked. I am in a fix as all the streamlit applications are down due to this.
I’m afraid I don’t have a solution for it just yet. Did you try killing and restarting the apps after the update? Do you also run into the error when using the python -m streamlit run app.py format?
Note: streamlit.cli has moved to streamlit.web.cli
Yes, I tried all that you mentioned; rebooted the machine too. Didn’t work. Uninstalled Streamlit and found that it could still invoke version 0.87.
Promptly installed version 1.11 thereafter and everything was fine. I think I’ll skip 1.12 and move to the next version whenever it becomes available. 1.12 has me spooked.
Thanks once again for your suggestions and support.