Closed jnumainville closed 3 months ago
@mofojed I still have one more issue as mentioned but I'm not sure what's wrong. If it's easier we can get this review done and I can create a new issue.
Sometimes, when the streamlit tab opens after running streamlit run streamlit_deephaven/test_app.py
an error appears in streamlit because the object is not found. It's not appearing in the panels list either.
It seems to happen more if I have lots of tabs open but I am not 100% sure as it happens consistently but I don't have a deterministic recreation.
So, something is going wrong such that a table added to __main__.__dict__
is not grabbed by the server.
Fixes #7 Moved most code to
streamlit_deephaven.py
and removedDEV_MODE
since runningtest.py
directly is no more difficult.Fixes #8 Fixed through moving server start code to a cache resource to ensure it is only ran once.
Fixes #9 Added
_remove_widgets()
, which is called every time the server reruns.Fixes #10 Added a random nonce. I'm not sure if it really matters but I used a completely random one rather than the id of the widget as the id of the widget is the memory address in CPython.