From 796ccaad0d9efea46d1da1e710a3a650c43031c8 Mon Sep 17 00:00:00 2001 From: Tim Abbott Date: Fri, 12 Oct 2012 15:46:42 -0400 Subject: [PATCH] zephyr_mirror: Avoid printing Hesiod errors to stderr. (imported from commit 2f0016b196d764027e4e53a937167d04b3e96f49) --- zephyr_mirror.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/zephyr_mirror.py b/zephyr_mirror.py index 38919f9..55bc348 100755 --- a/zephyr_mirror.py +++ b/zephyr_mirror.py @@ -89,7 +89,8 @@ def fetch_fullname(username): match_user = re.match(r'([a-zA-Z0-9_]+)@mit\.edu', username) if match_user: proc = subprocess.Popen(['hesinfo', match_user.group(1), 'passwd'], - stdout=subprocess.PIPE) + stdout=subprocess.PIPE, + stderr=subprocess.PIPE) out, _err_unused = proc.communicate() if proc.returncode == 0: return out.split(':')[4].split(',')[0]