Python Dash App is Not Rendering in Browser

39 Views Asked by At

I tried to run the following example code from https://dash.plotly.com/tutorial but it just gives me a blank browser tab which seems to infinitely load:

from dash import Dash, html

app = Dash(__name__)

app.layout = html.Div([
    html.Div(children='Hello World')
])

if __name__ == '__main__':
    app.run(debug=True)

Is it blocked by something? How to unblock it?

2

There are 2 best solutions below

2
ArtyLee On

I managed to get the example work without any changes in code. I also saw infinite time loading of the page "http://127.0.0.1:8050/". After I allowed Javascript, the page loaded successfully showing "Hello World". Maybe you also blocked Javascript or this port 8050?

0
tover On

For whatever reason a simple computer restart did the trick. Now it runs.