obspy.core.util.misc.SuppressOutput

SuppressOutput()[source]

A context manager that suppresses output to stdout/stderr. Always use with “with” statement. Does nothing otherwise. >>> with SuppressOutput(): # doctest: +SKIP ... os.system(‘echo “mystdout”’) ... os.system(‘echo “mystderr” >&2’)

Note: Does not work reliably for Windows Python 3.6 under Windows - see function definition of _py36_windowsconsoleio_workaround().