Skip to content
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

Make default stderr sys.stderr, not passthrough #164

Merged
merged 20 commits into from
Nov 14, 2024
Merged

Make default stderr sys.stderr, not passthrough #164

merged 20 commits into from
Nov 14, 2024

Conversation

ayjayt
Copy link
Collaborator

@ayjayt ayjayt commented Nov 13, 2024

Change default stderr to sys.stderr, not passthrough

else:
stderr = debug_browser

# awful
if stderr and stderr != subprocess.PIPE and stderr != subprocess.STDOUT and stderr != subprocess.DEVNULL and not isinstance(stderr, int):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that this can be easy to read if you create some variables with some conditionals, like:

stuff_1= stderr != subprocess.PIPE
stuff_2 = stderr != subprocess.STDOUT
stuff_3 = stderr != subprocess.DEVNULL
if stderr and  stuff_1 and stuff_2 and stuff_3 and not isinstance(stderr, int):

or

stuff = [subprocess.PIPE, subprocess.STDOUT, subprocess.DEVNULL]
if stderr and  stderr not in stuff and not isinstance(stderr, int):

@ayjayt
Copy link
Collaborator Author

ayjayt commented Nov 14, 2024

When this gets merged, we need to get up to 0.99.6

@ayjayt ayjayt merged commit 83a6ea9 into main Nov 14, 2024
4 checks passed
@ayjayt ayjayt deleted the andrew/sys-out branch November 14, 2024 20:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants