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
os.popen2 and os.popen3 in python 2.6 incompatible with os.popen* in python 2.5 #49579
Comments
The implementation in python 2.6 expects the cmd argument to be a string. This difference may cause programs that work with python 2.5 to fail I have tested the patch attached with one of my scripts that failed with |
Adding a couple of unit tests would be nice. |
With or without tests, this is a regression from Python 2.5 - shouldn't |
The test is the proof the the regression, and shows the change in os.popen3() accepts a sequence, except that since 2.6, the first item is Your patch is correct. A unit test could be: |
Attached os-popen-list.patch which includes all of the earlier |
The subprocess docs (in Doc/library/subprocess.rst and the module itself) |
Hey Philip, I'm not sure I follow. The patch only changes the os module, not the |
Sorry, I meant the docs describing how to convert os.popen* calls to |
Ah, thanks for the clarification, Philip. I've attached another patch |
Here's the doc change with a lil more clarification, and I've also applied |
applied in r75143/r75144, in time for 2.6.3. thanks! |
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: