summaryrefslogtreecommitdiffstats
path: root/py3status
diff options
context:
space:
mode:
authorUltrabug <ultrabug@gentoo.org>2013-12-09 10:12:41 +0100
committerUltrabug <ultrabug@gentoo.org>2013-12-09 10:12:41 +0100
commitd72dd6cea99d0a75eab9f29757eacaaf1b3560c2 (patch)
treec9174941e63739d0f345cc22cc6607d73b433108 /py3status
parentd76358ef2cc6e645f6be94c136369b7f27366ff7 (diff)
redirect stdout and stderr to null to suppress modules outputs
Diffstat (limited to 'py3status')
-rwxr-xr-xpy3status/__init__.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/py3status/__init__.py b/py3status/__init__.py
index 68d491f..5d36b2e 100755
--- a/py3status/__init__.py
+++ b/py3status/__init__.py
@@ -601,6 +601,10 @@ class Py3statusWrapper():
if self.config['debug']:
syslog(LOG_INFO, 'events thread started')
+ # suppress modules' ouput wrt issue #20
+ sys.stdout = open('/dev/null', 'w')
+ sys.stderr = open('/dev/null', 'w')
+
# load and spawn modules threads
for include_path, f_name in self.list_modules():
try: