You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The documentation provided is quite lacking in locustfiles that do any imports of helper modules. It seems to imply that you will always have a completely flat directory structure of locustfiles like:
cwd/
locustfile1.py
locustfile2.py
locustfile3.py
But one of the big advantages of locust is creating complex user behaviors that may require additional logic and data to be shared across locustfiles, such as configs or auth. Similar to how most applications are run, we should think about whether we want to continue to have the locustfile be the "root" from which to import or if we want to have a root dir that contains multiple locustfiles. e.g.:
See #484, which proposes including the cwd in the path, but I think this might have undesirable side effects for current integrations. I think we can go that route, but official docs should recommend only running from the project root (locustproject) in the example above.
The text was updated successfully, but these errors were encountered:
I gave it a crack (#501). I might be missing some spots, but first let me know if you think this is better or worse. I think my change sufficiently exposes alternatives to flat-directory projects.
The documentation provided is quite lacking in locustfiles that do any imports of helper modules. It seems to imply that you will always have a completely flat directory structure of locustfiles like:
But one of the big advantages of locust is creating complex user behaviors that may require additional logic and data to be shared across locustfiles, such as configs or auth. Similar to how most applications are run, we should think about whether we want to continue to have the locustfile be the "root" from which to import or if we want to have a root dir that contains multiple locustfiles. e.g.:
See #484, which proposes including the cwd in the path, but I think this might have undesirable side effects for current integrations. I think we can go that route, but official docs should recommend only running from the project root (
locustproject
) in the example above.The text was updated successfully, but these errors were encountered: