@st.experimental_singleton supports an optional validate parameter that accepts a validation function for cached data and is called each time the cached value is accessed.
Hi @TomJohn , could you possibly create a bug report for this? Someone on our team is usually look at github issues but not the forum so sometimes these bug reports on the forum get lost!
(DataSci) D:\SciDirectScraper>streamlit run vis.py
Traceback (most recent call last):
from streamlit.delta_generator import DeltaGenerator as _DeltaGenerator
File "D:\DataSci\lib\site-packages\streamlit\delta_generator.py", line 75, in <module>
from streamlit.elements.plotly_chart import PlotlyMixin
File "D:\DataSci\lib\site-packages\streamlit\elements\plotly_chart.py", line 41, in <module>
import streamlit.elements.lib.streamlit_plotly_theme
File "D:\DataSci\lib\site-packages\streamlit\elements\lib\streamlit_plotly_theme.py", line 116, in <module>
go.layout.template.data.Icicle(textfont=go.icicle.Textfont(color="white"))
File "D:\DataSci\lib\site-packages\_plotly_utils\importers.py", line 41, in _getattr_
name=import_name, __name__=parent_name
AttributeError: module 'plotly.graph_objs.layout.template.data' has no attribute 'Icicle'
I am also getting same error after installing stramlit-1.17.0 and upgrading plotly does not resolve the issue.
Will have to go with older version of streamlit I guess to make it work as of now.
As @Goyo rightly pointed out, the issue is with your plotly version being too old. Icicle charts were released in Plotly 5.0.0, two years ago in June.
You need to install a version of Plotly >= 5.0.0. Here’s a screenshot of my Terminal when I have an older version and newer version that supports Icicle charts. It is clear the issue stems from older Plotly versions:
Hi Shweta, it would be a good idea to upgrade. Can you give us some more information as to what’s going on for plotly not working? I would guess it has to deal with your dev environment.
Can you explain to me your dev environment so that we can get that resolved?