nkozlovskiy 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago | |
---|---|---|
.. | ||
testdata | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
ChangeLog | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
LICENSE | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
README.md | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
_posixsubprocess.c | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
_posixsubprocess_config.h | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
_posixsubprocess_helpers.c | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
subprocess32.py | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
test_subprocess32.py | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
ya.make | 6295ef4d23 oss ydb: fix dstool building and test run | 1 year ago |
This is a backport of the Python 3 subprocess module for use on Python 2. This code has not been tested on Windows or other non-POSIX platforms.
subprocess32 includes many important reliability bug fixes relevant on POSIX platforms. The most important of which is a C extension module used internally to handle the code path between fork() and exec(). This module is reliable when an application is using threads.
Refer to the Python 3.5 subprocess documentation for usage information.
The recommend pattern for cross platform code is to use the following:
if os.name == 'posix' and sys.version_info[0] < 3:
import subprocess32 as subprocess
else:
import subprocess
Or if you fully control your POSIX Python 2.7 installation, this can serve as a replacement for its subprocess module. Users will thank you by not filing concurrency bugs.
Try to reproduce them on the latest Python 3.x itself and file bug reports on bugs.python.org. Add gregory.p.smith to the Nosy list.
If you have reason to believe the issue is specifically with this backport and not a problem in Python 3 itself, use the github issue tracker.
-- Gregory P. Smith greg@krypto.org