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
python -v writes to stderr #79827
Comments
Subprocess.Popen('python -v',stdout=PIPE,stderr=PIPE,Shell=True) Prduces output in stderr instead of stdout. For others: pip --version or git --version output is in stdout and is expected. |
-v writes to stderr, so this is the expected behavior. Although maybe this could be better documented. See bpo-18338, where this was briefly discussed and a change was rejected. Maybe you're looking for -V (uppercase) or --version, which do write to stdout, at least in 3.x. I'm not sure where they write in 2.7, but it's much too late to change 2.7's behavior. I'm going to close this. If you find some of our documentation that says -v writes to stdout, then we can reopen this. This is not a Windows specific error, so I'm modifying the nosy list. |
Hello, -V and --version both write to stderr not stdout. On Thu, 3 Jan 2019, 1:29 pm Eric V. Smith <report@bugs.python.org wrote:
|
That's just the way it is with 2.7. |
Thank you for the reply Eric. On Thu, 3 Jan 2019, 2:28 pm Eric V. Smith <report@bugs.python.org wrote:
|
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: