bcgsc / NanoSim

Nanopore sequence read simulator
Other
233 stars 56 forks source link

Simulator execution error: "ImportError: No module named request" #125

Closed ChristosMatzoros closed 2 years ago

ChristosMatzoros commented 3 years ago

Hello,

When I try to run simulator.py, even with no parameters I get this:

./simulator.py Traceback (most recent call last): File "./simulator.py", line 23, in from urllib.request import Request, urlopen ImportError: No module named request

I have installed all the required packages so I do not know what exactly is the problem in my case. Do I need to change the code?

cheny19 commented 3 years ago

Hi @ChristosMatzoros , urllib.request is for Python3. Could you make sure you are running NanoSim with Python3 instead of Python2? It is likely that you have both Python2 and 3, but your default is Python2 when running .py files, so this error occurs.

SaberHQ commented 2 years ago

Hey @ChristosMatzoros were you able to successfully run NanoSim with Python3? I hope @cheny19 's suggestion worked for you. I am closing this issue as for now. Please feel free to reopen it if you still got issue with NanoSim. Cheers.