dash.Dash.css.config.serve_locally = True
dash.Dash.scripts.config.serve_locally = True
dash.Dash.css
if name == ‘main’:
dash.Dash.run_server(debug=True)
and running into
AttributeError: type object ‘Dash’ has no attribute ‘css’
if I remove dash.Dash.css.config.serve_locally - True, I run into
AttributeError: type object ‘Dash’ has no attribute ‘scripts’
I did try it with app yesterday and it didn’t work but somehow when I copied your code here, it’s doing fine. But now I am getting ‘* Restarting with stat’ and then that’s it. Doesn’t show or do anything. Did I miss any installation?
Ok, so you miss copy the tutorial. Furthermore, you mixed different tutorial (there is no css related stuff in this tuto).
So, if you do not see anything else in the terminal, it means that everything is fine, and you can go to http://localhost:8050/ and see your app.
This is what your terminal should say:
>>> python3 test.py
* Running on http://127.0.0.1:8050/ (Press CTRL+C to quit)
* Restarting with stat
dash.Dash-Not really. That was me misunderstanding a post to try to troubleshoot the given error
‘app.css.config.serve_locally = True’ - This is to try and run it locally in my pc. Is there a way to run this offline and save it in my PC?
hello guys am also trying to get started with dash , have created the file and the code is okay but when i try to run it am getting this error
Traceback (most recent call last):
File “C:\Users\MASELA\Desktop\dash\app.py”, line 31, in
app.run_server(debug=True)
File “C:\Python27\lib\site-packages\dash\dash.py”, line 1058, in run_server
**flask_run_options)
File “C:\Python27\lib\site-packages\flask\app.py”, line 938, in run
cli.show_server_banner(self.env, self.debug, self.name, False)
File “C:\Python27\lib\site-packages\flask\cli.py”, line 629, in show_server_banner
click.echo(message)
File “C:\Python27\lib\site-packages\click\utils.py”, line 218, in echo
file = _default_text_stdout()
File “C:\Python27\lib\site-packages\click_compat.py”, line 675, in func
rv = wrapper_func()
File “C:\Python27\lib\site-packages\click_compat.py”, line 243, in get_text_stdout
rv = _get_windows_console_stream(sys.stdout, encoding, errors)
File “C:\Python27\lib\site-packages\click_winconsole.py”, line 295, in _get_windows_console_stream
func = _stream_factories.get(f.fileno())
UnsupportedOperation: fileno
Although I have seen people having issues winning from within IDEs before. So if it’s not working, perhaps try running from the command line rather than from Spyder