-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Question: Why don't use base_url param value from pytest.ini when running with pytest-xdist? #34
Comments
pytest-base-url/src/pytest_base_url/plugin.py Lines 36 to 43 in a88f70a
this seems to be intended to set up the details, as far as i understood that works as intended |
Why was the base_url not instantiated for the xdist workers configuration? |
the options are passed by pytest from the controller to the worker the configure hook sets the option |
starting pytest-xdist==1.30.0(Oct 1, 2019) base_url is not shared between controller and workers. this changed in https://github.com/pytest-dev/pytest-xdist/blob/30b540cd1f70266fbb88883407a9b85dff0e1cb0/src/xdist/workermanage.py#L244 |
Good catch |
Closing this as it seems to be out-of-scope for this plugin. Feel free to reopen if you think otherwise. |
Hi @RonnyPfannschmidt @BeyondEvil, I have the same question with the issue title.
It works though when passing the URL as an argument |
There's a workaround if you follow the link to the (still open) issue over at pytest-xdist: #34 (comment). @sayurionishi |
Yes, saw this thread when searching for this issue. Thanks @BeyondEvil |
This one is a longstanding pytest bug thats hard to unravel |
Hi,
Thats not critical issue for me but it still interest.
Why we don't read base_url param value from pytest.ini when run tests with pytest-xdist plugin?
I try replace line https://github.com/pytest-dev/pytest-base-url/blob/master/src/pytest_base_url/plugin.py#L14
by
base_url = config.getoption("base_url") or config.getini("base_url")
and this worked for meThe text was updated successfully, but these errors were encountered: