-
-
Notifications
You must be signed in to change notification settings - Fork 32.1k
gh-128438: Add EnvironmentVarGuard
for test_pdb.py
#128522
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
Conversation
EnvironmentVarGuard
for test_pdb.pyEnvironmentVarGuard
for test_pdb.py
EnvironmentVarGuard
for test_pdb.py
EnvironmentVarGuard
for test_pdb.py
Lib/test/test_pdb.py
Outdated
if homesave is not None: | ||
os.environ['HOME'] = homesave | ||
return stdout, stderr | ||
return stdout, stderr |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leave this return
statement out of with
and it should be good to go.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 , addressed
@gaogaotiantian can this be backported to ease future backports or do you prefer to leave it like that? (namely, is there any chance that those lines can be changed in future versions?) |
I think it's fine to keep it as it is for previous versions. I don't expect frequent changes to these lines and it's definitely not a bug fix. |
EnvironmentVarGuard
in tests instead of manually messing withos.environ
#128438