AttributeError: module 'dash' has no attribute 'Dash'

Im a beginner, till yesterday i was running a code, wich was running fine, but today when i ran the same code, it started giving me this error below:

“Traceback (most recent call last):
File “”, line 1, in
import dash as dash
File "C:\Users\BG\AppData\Local\Continuum\anaconda3\lib\site-packages\dash_init
.py”, line 1, in
from .dash import Dash, no_update # noqa: F401
File “C:\Users\BG\AppData\Local\Continuum\anaconda3\lib\site-packages\dash\”, line 18, in
from future.moves.urllib.parse import urlparse
File “C:\Users\BG\AppData\Local\Continuum\anaconda3\lib\site-packages\future\”, line 8, in
File “C:\Users\BG\AppData\Local\Continuum\anaconda3\lib\site-packages\future\”, line 810, in import_top_level_modules
with exclude_local_folder_imports(*TOP_LEVEL_MODULES):
File “C:\Users\BG\AppData\Local\Continuum\anaconda3\lib\site-packages\future\”, line 781, in enter
module = import(m, level=0)
File “C:\Users\BG\Desktop\Cogencis Office\Cogencis Project\financialreport\”, line 3, in
from jupyter_dash import JupyterDash
File “C:\Users\BG\AppData\Local\Continuum\anaconda3\lib\site-packages\”, line 2, in
from .jupyter_app import JupyterDash
File “C:\Users\BG\AppData\Local\Continuum\anaconda3\lib\site-packages\jupyter_dash\”, line 26, in
class JupyterDash(dash.Dash):
AttributeError: module ‘dash’ has no attribute ‘Dash’

I searched over internet to interpret this but i couldn’t… Tried with the code as basic as

import dash
import dash_core_components as dcc
import dash_html_components as html

app = dash.Dash()
app.layout = html.Div([


Still even this is not working. Can anyone help ?

1 Like

do you happen to have a file named The JupyterDash code might be importing that file instead of importing the dash module.

1 Like

No, i don’t have any file with that name, i just now activated my conda base and opened a new jupyter notebook to run my .py file.

IT WORKED !! , still couldn’t understand exactly what had happened.

Interesting. I just ran into the same problem with a file called in that directory.

1 Like

Same trouble using a file. Just change name and it works :thinking: is the problem, change it. it will be work right away.

If there is a file in your directory, this error will happen if you try to run this file or any other file in that directory.

It worked after deleting file from directory.