-
Notifications
You must be signed in to change notification settings - Fork 12
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
Sharing data between callbacks error #31
Comments
@GibbsConsulting : Did you get a chance to look into above question? Please let me know if you need additional information. Thanks! |
If you are going to remain within a Jupyter notebook, then you can use the notebook environment to store state. This would avoid the need to use an external cache or similar, but at the same time would require code changes to not use the cache. Going forward, we could add a cache variant to make this relatively transparent. See GibbsConsulting/django-plotly-dash#120 |
Ok, are you aware of any example code to store the state within notebook? If yes, it will help me integrating it into dash apps within notebooks. Regarding the cache variant implementation in jupyter-plotly-dash, is there any tentative timeline as to when this feature could be completed? Thanks! |
Just reference a local (to the notebook) variable in a callback. The value used will be that of the time the callback is invoked. Note that changing the value of the variable will not automatically propagate to the Dash app until a callback is invoked. |
Hi,
I am trying to execute the example code given in Dash user guide and documentation explaining Caching and Signaling concept of Sharing data between callbacks - https://dash.plot.ly/sharing-data-between-callbacks , when I try to integrate this code in JupyterDash and run in notebook cell it gives me the following error:
AttributeError Traceback (most recent call last)
in
18 #app = dash.Dash(name, external_stylesheets=external_stylesheets)
19 app=JupyterDash('Caching and Signaling')
---> 20 cache = Cache(app.server, config={
21 'CACHE_TYPE': 'redis',
22 # Note that filesystem cache doesn't work on systems with ephemeral
AttributeError: 'JupyterDash' object has no attribute 'server'
Am I doing something wrong here or how can we get this example working in Jupyter-plotly-dash?
Complete code file (.py) is attached in the zip file
Thanks!
Caching_Signaling_jupyter-plotly-dash.zip
The text was updated successfully, but these errors were encountered: