Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
ModuleNotFoundError
#1
I am trying to run a code that works in another laptop but not sure why i am getting the following error message:

ModuleNotFoundError: No module named 'bresenham'

i googled this error and found that i needed to install:

pip install bresenham

but i am still getting the same error message.
Reply
#2
Some tedious but necessary questions:

Do you have more than one version of python installed?
A separate version of pip comes with each version.

Are you running in a virtual environment?
And, if so has it been activated.

If all of the above is OK,
from command line

check python version: python -V
and then pip pip -V

do the versions match?

next make sure package shows in pip pip list

If you get this far, try running your script from the command line with python myscript.py, replacing myscript with your script name.

Do you get the same error?

last, did you use this command to install bresenham python -m pip install bresenham?
see GitHub page here: https://github.com/encukou/bresenham
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020