test_which: do not mutate os.environ (#41215)#41215
Conversation
2991e2c to
45fa86c
Compare
ea73fc3 to
272d23e
Compare
|
What's the goal of removing |
|
The PR is about fixing unit test failures in GitHub Actions that seemingly all have to do with environment variables being empty / unset. The only thing @alalazo found was an xdist upgrade that maybe changes the order in which tests are scheduled, so there's likely an pre-existing issue |
|
@alalazo actually rhel is failing now, probably due to PYTHONPATH not being set, but there we don't even use xdist |
|
Can we use this #41214 and add a revert commit to this PR (to be merged when ready?) |
d070c0e to
0263c9b
Compare
|
Pretty confident the issue is fixed now, I accidentally broke unrelated tests previously. |
os.environ pollution in test_which
os.environ pollution in test_whichtest_which: do not mutate os.environ (#41215)
test_which: do not mutate os.environ (#41215)test_which: do not mutate os.environ (#41215)
|
There are a few other cases but they just add an env variable which is not very disruptive... will submit a separate cleanup pr tomorrow. |
closes #41214
Uncovered by xdist reordering test execution, there's (at least?) one test that modifies os.environ globally.