I am trying the locust quick start in my mac and I am getting this error for any import I try. I have python 2.7 and python 3.7 installed in my machine but i use only python 3.7
➜ ~ python -V
Python 2.7.16
➜ ~ python3 -V
Python 3.7.5
my locust version is: 1.4.3
Traceback (most recent call last):
File "<frozen importlib._bootstrap>", line 983, in _find_and_load
File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 677, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 728, in exec_module
File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
File "/Users/xxxxx/xxxxx/xxxxx/xxxxx/locust.py", line 3, in <module>
from locust import HttpUser, task, between
ImportError: cannot import name 'HttpUser' from 'locust' (/Users/xxxxx/xxxxx/xxxxx/xxxxx/locust.py)```
python3 -m pip list
does the module show up there? Are you usingpython3 -m pip install
to install modules? – Scenography