0

After following the quick start from https://hypothesis.readthedocs.io/en/latest/quickstart.html I import the hypothesis, when i run the code I get this -> ModuleNotFoundError: No module named 'hypothesis'

pip install hypothesis

import hypothesis

from titleCost import *
from hypothesis import given, settings,Verbosity, text, strategies as some

UPDATE: if anyone has this error follow this link Unable to import a module that is definitely installed . This helped me through it and worked out.

gma2022
  • 1
  • 1
  • Does this answer your question? [ImportError after successful pip installation](https://stackoverflow.com/questions/32680081/importerror-after-successful-pip-installation) – mkrieger1 Mar 15 '23 at 23:43
  • This usually means your Python isn't the same as your pip. Are you running Python from inside an IDE? Which one, exactly? – Tim Roberts Mar 15 '23 at 23:44
  • @mkrieger1 I looked into that post and I run the recommended install but still can't seem to find the library. – gma2022 Mar 15 '23 at 23:54
  • @TimRoberts Im running python from the inside of my IDE on a conda virtual environment. – gma2022 Mar 15 '23 at 23:56
  • 2
    The you have to install hypothesis through conda. – Tim Roberts Mar 16 '23 at 01:33
  • @TimRoberts any other ideas? That doesn't work as well, tried "conda install hypothesis" and returns all requested packages already installed. – gma2022 Mar 16 '23 at 03:21
  • Which IDE are you using? Again, it could have it's own installation of Python. – Tim Roberts Mar 16 '23 at 03:25
  • 1
    @TimRoberts I was using VSCode. I found this https://stackoverflow.com/q/14295680/19090647 . I ran the following "sudo uninstalled hypothesis", then "sudo -H install hypothesis" and right away my imports worked. – gma2022 Mar 16 '23 at 03:52

0 Answers0