stdout_stderr_capturing
Capture the stdout or stderr output as a list in a context manager block (with).
Maybe better alternatives:
Capture stdout:
with Capturing() as output:
print('line 1')
print(output[0])
is equivalent to
with Capturing(stream='stdout') as output:
print('line 1')
Capture stderr:
with Capturing(stream='stderr') as output:
print('line 1', file=sys.stderr)
Metadata
Release files for stdout_stderr_capturing 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| stdout_stderr_capturing-0.2.1.tar.gz | 2.7 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| stdout_stderr_capturing-0.2.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 6.2 kB
Release files / stdout_stderr_capturing-0.2.1.tar.gz
| Download URL | stdout_stderr_capturing-0.2.1.tar.gz |
|---|---|
| Size | 2.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
bd220cb95464b6270c78b9e6126cd2c7eba2eb0e3874df43a27e32513be67f5d
|
|
BLAKE2b-256 checksum How to use checksums |
11433667093c708d765ec818213f01fdb0bb01934295a904678e093a190e127e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.1 CPython/3.12.1 Linux/6.2.0-1019-azure
|
Release files / stdout_stderr_capturing-0.2.1-py3-none-any.whl
| Download URL | stdout_stderr_capturing-0.2.1-py3-none-any.whl |
|---|---|
| Size | 3.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c01ce47f1328de157dd197a70331011ee93b4a57330211100f013e67c4f82240
|
|
BLAKE2b-256 checksum How to use checksums |
419c035ac9e6cfcbc7197c92ee8402f60e830b42488661828e946608b3e6bb6b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.1 CPython/3.12.1 Linux/6.2.0-1019-azure
|