0

I'm working on my LocustFile and discovered SequentialTaskSet, but when I try to import it as I see countless times in examples and documentation, I get an error:

lmint/ERROR/stderr: cannot import name 'SequentialTaskSet' from 'locust' (/home/cameron/.pyenv/versions/3.7.5/lib/python3.7/site-packages/locust/__init__.py)

my python version is 3.7.5, locust 2.22.0 . What can I do to debug this issue? I cannot accomplish what I need to do without sequential tasks.

EDIT: The Locustfile and overall project can be viewed on github here

2 Answers2

1

Per the comment from @cyberwiz, I was using an ancient version of locust resulting from installing locustio from pypi instead of locust. Upgrading it did allow me to import SequentialTaskSet, so I am closing this question.

0

No Locust version with the version number 2.22.0 exists. What does it say if you run locust --version?

Make sure that you've installed the locust PyPI package, and not the locustio package (which was used for 0.x versions of Locust and doesn't have SequentialTaskSet).

heyman
  • 4,845
  • 3
  • 26
  • 19