Updated dash, getting an error

Hello,
So after updating dash-core-components & dash, I can’t start my app. Dash says it can’t find plotly-1.42.2.min.js. I know dash-core-components are now using 1.44.3, but how can I tell Dash to use the new one. Sorry if I’m not clear, I’m really not used to updating packages, first time I break a dependency.

Thank you

Edit: Managed to get it working by downgrading to 0.36 version of dash-core-components that uses 1.42.2. Still don’t know why the new one does not work.

Hm, that’s odd. Could you share a small, reproducable example?

Sure thing, thx for the reply, from the man itself :grinning:
I’ve reupgraded to 0.43.1 for the test.

Here’s the error message I get:
[2019-02-13 12:22:04,415] ERROR in app: Exception on /favicon.ico [GET]
Traceback (most recent call last):
File “C:\ProgramData\Anaconda3\lib\site-packages\flask\app.py”, line 1982, in wsgi_app
reraise(TypeError, new_error, sys.exc_info()[2])
File “C:\ProgramData\Anaconda3\lib\site-packages\flask\app.py”, line 1607, in full_dispatch_request
“”"Return a registered error handler for an exception in this order:
File “C:\ProgramData\Anaconda3\lib\site-packages\flask\app.py”, line 1654, in try_trigger_before_first_request_functions
exception is not called and it shows up as regular exception in the
File “C:\ProgramData\Anaconda3\lib\site-packages\dash\dash.py”, line 945, in _setup_server
args = []
File “C:\ProgramData\Anaconda3\lib\site-packages\dash\dash.py”, line 388, in _generate_scripts_html
for resource in resources:
File “C:\ProgramData\Anaconda3\lib\site-packages\dash\dash.py”, line 336, in _collect_and_register_resources
}
File “C:\ProgramData\Anaconda3\lib\site-packages\dash\dash.py”, line 322, in _relative_url_path
def serve_layout(self):
FileNotFoundError: [WinError 2] Le fichier spécifié est introuvable: ‘C:\ProgramData\Anaconda3\lib\site-packages\dash_core_components\plotly-1.42.2.min.js’
127.0.0.1 - - [13/Feb/2019 12:22:04] “GET /favicon.ico HTTP/1.1” 500 -

And as for the code, I used your first tutorial for the example:

import dash
import dash_table
import pandas as pd

df = pd.read_csv('https://raw.githubusercontent.com/plotly/datasets/master/solar.csv')

app = dash.Dash(__name__)

app.layout = dash_table.DataTable(
    id='table',
    columns=[{"name": i, "id": i} for i in df.columns],
    data=df.to_dict("rows"),
)

if __name__ == '__main__':
    app.run_server(debug=False)

Can you show us pip freeze or conda list if using conda ?

I have a boat load of packages in my root env, but here’s a list:

  • List item
    dash-core-components 0.43.1
    dash 0.37.0
    dash-renderer 0.18.0
    dash-table 3.4.0
    dash-table-experiments 0.6.0
    flask 0.12
    plotly 3.6.1

Otherwise I can get the whole list and paste it, let me know, thank you

The version you listed all works, I do not get the error. I’d recommend starting with a fresh environment and installing only dash==0.37.0.

Roger that. That’s what I did and it works now, good old “start from scratch” solution, but it worked, thank you for the follow up.

1 Like