Skip to main content

Captures stdout

Project description

Captures stdout

pip install capture-stdout-decorator
from capture_stdout_decorator import print_capture

@print_capture

def hahaha():

    print("babab")

    return 4

@print_capture(print_output=False, return_func_val=False)

def hahaha2():

    print("babab")

    return 4

x = hahaha()

print(f'{x=}')

y = hahaha2()

print(f'{y=}')



# output:

babab

x=(4, 'babab\n')

y='babab\n'

		

Project details


Release history Release notifications | RSS feed

This version

0.10

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

capture_stdout_decorator-0.10.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

capture_stdout_decorator-0.10-py3-none-any.whl (4.6 kB view details)

Uploaded Python 3

File details

Details for the file capture_stdout_decorator-0.10.tar.gz.

File metadata

File hashes

Hashes for capture_stdout_decorator-0.10.tar.gz
Algorithm Hash digest
SHA256 3050c7511491f0607605e6c043a0c4b5edc8c7fc02e5a36895ff3ad80baeddb9
MD5 1ca416cc494fed3ebf532df0dc64b5c0
BLAKE2b-256 1152af819e625edb0b66a7913e4e77de77d16b1832816b44a1ed1a97a5e97407

See more details on using hashes here.

File details

Details for the file capture_stdout_decorator-0.10-py3-none-any.whl.

File metadata

File hashes

Hashes for capture_stdout_decorator-0.10-py3-none-any.whl
Algorithm Hash digest
SHA256 ec61ae42a7558f0751476320c29ff2bd11edf5e44763a95bc40fce1c5adb6605
MD5 86e8f44e34365a78d8cd1314523c8163
BLAKE2b-256 dee17c95f014a63970bedd455884277e47015a05788c85b7b3f2cb7a9ee837e5

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page