I am getting: "ModuleNotFoundError: No module named xx", even if "pip install xx" has been used

Hello,

I don't understand what is the problem,

Here is an example script:

​

import dash

import dash_cytoscape as cyto import dash_html_components as html

app = dash.Dash(name) app.layout = html.Div([ cyto.Cytoscape( id='cytoscape', elements=[ {'data': {'id': 'one', 'label': 'Node 1'}, 'position': {'x': 50, 'y': 50}}, {'data': {'id': 'two', 'label': 'Node 2'}, 'position': {'x': 200, 'y': 200}}, {'data': {'source': 'one', 'target': 'two','label': 'Node 1 to 2'}} ], layout={'name': 'preset'} ) ])

if name == 'main': app.run_server(debug=True)

​

Despite doing all of the following:

  1. Using "pip install dash_cytoscape" - inside the terminal of my ENV made on anaconda.

  2. Opening the list of libraries of the ENV on anaconda UI, and doing a "research" to fine the same library and installing it manually

  3. Trying a solution suggested here (https://blog.finxter.com/fixed-python-modulenotfounderror-no-module-named-dash/) => "Solution Idea 2: Fix the Path"

​

I am still getting:

C:\user\folder>py c5.py

Traceback (most recent call last): File "C:\user\folder\c5.py", line 2, in <module> import dash_cytoscape as cyto ModuleNotFoundError: No module named 'dash_cytoscape'

I am soo confused. What's the problem here?

Why is it not working?

Posted Oct 9, 2023, 10:10 AM UTC

11
Loading comments…