From d8dfa1c5d5f6626954c13a96bd930f3ce710f5a0 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sat, 9 May 2020 15:58:40 +0200 Subject: [PATCH] We gotta trash the error stream because gzip complains about broken pipe when ran in python subprocess ~.~ --- src/yunohost/utils/packages.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/yunohost/utils/packages.py b/src/yunohost/utils/packages.py index 6103206e5..51e9ab71a 100644 --- a/src/yunohost/utils/packages.py +++ b/src/yunohost/utils/packages.py @@ -40,7 +40,7 @@ def get_ynh_package_version(package): # may handle changelog differently ! changelog = "/usr/share/doc/%s/changelog.gz" % package - cmd = "gzip -cd %s | head -n1" % changelog + cmd = "gzip -cd %s 2>/dev/null | head -n1" % changelog if not os.path.exists(changelog): return {"version": "?", "repo": "?"} out = check_output(cmd).split()