AnnMarieW / dash-multi-page-app-demos

Minimal examples of multi-page apps using Dash Pages
221 stars 52 forks source link

Not Found The requested URL was not found on the server #7

Closed joytsay closed 1 year ago

joytsay commented 1 year ago

Hi, Thanks for the multipage examples! I have been dealing with this issue, e.g. \multi_page_example1 Every time I initially go to http://127.0.0.1:8050 ("/" root page) when app.run_server(debug=True) it shows:

NotFound
werkzeug.exceptions.NotFound: 404 Not Found: The requested URL was not found on the server. If you entered the URL manually please check your spelling and try again.

and in app.run_server(debug=True)

Not Found
The requested URL was not found on the server. If you entered the URL manually please check your spelling and try again.

after reloading this page, it loads the contents as usual, however I need to click the refresh button on the browser everytime : (

I searched high and low for similar issues e.g.: https://stackoverflow.com/questions/73784593/running-dash-on-a-public-ip-werkzeug-exceptions-notfound-404-not-found But this doesn't solve the problem.

I use conda as virtual environment, and run dash simply by running python app.py (Serving Flask 'app' lazy loading) Am I doing something wrong with my environment settings? Or can I tweak the code to meet my means. Thanks!

AnnMarieW commented 1 year ago

Hi @joytsay I'm glad you are finding the examples helpful :slightly_smiling_face:

This sounds like an issue from an early version of Pages. Can you make sure you are running the most current version of dash? (2.7.0)

To see what version you are actually running, add the following to the app.py :

import dash
print(dash.__version__)
joytsay commented 1 year ago

OMG the problem is fixed! yes I was using dash 2.6.0 after upgrading todash 2.7.0the problem went away : )))) Thanks for the quick reply!