From c6b89434b018c9b3ca3c13fb78bab20981fee6e6 Mon Sep 17 00:00:00 2001 From: Jakub Wilk Date: Sat, 28 Jul 2012 17:14:31 -0400 Subject: Fix typos: the the -> the (closes: #679432) --- apt/progress/base.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'apt') diff --git a/apt/progress/base.py b/apt/progress/base.py index ab57dd82..2c80ae29 100644 --- a/apt/progress/base.py +++ b/apt/progress/base.py @@ -65,7 +65,7 @@ class AcquireProgress(object): def media_change(self, media, drive): """Prompt the user to change the inserted removable media. - The parameter 'media' decribes the name of the the media type that + The parameter 'media' decribes the name of the media type that should be changed, whereas the parameter 'drive' should be the identifying name of the drive whose media should be changed. -- cgit v1.2.3 From f1b280f6e21d257411e63cbfdf6ccf0085689f9a Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Mon, 30 Jul 2012 13:23:53 +0200 Subject: apt/auth.py: Do not merge stdout and stderr (Closes: #678706) --- apt/auth.py | 10 +++++----- debian/changelog | 3 +++ 2 files changed, 8 insertions(+), 5 deletions(-) (limited to 'apt') diff --git a/apt/auth.py b/apt/auth.py index 5d4b1cd6..c52ec3a6 100644 --- a/apt/auth.py +++ b/apt/auth.py @@ -69,7 +69,7 @@ def _call_apt_key_script(*args, **kwargs): proc = subprocess.Popen(cmd, env=env, universal_newlines=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE, - stderr=subprocess.STDOUT) + stderr=subprocess.PIPE) content = kwargs.get("stdin", None) if isinstance(content, unicode): @@ -77,12 +77,12 @@ def _call_apt_key_script(*args, **kwargs): output, stderr = proc.communicate(content) - assert stderr == None - if proc.returncode: raise SystemError("The apt-key script failed with return code %s:\n" - "%s\n%s" % (proc.returncode, " ".join(cmd), - output)) + "%s\n" + "stdout: %s\n" + "stderr: %s" % (proc.returncode, " ".join(cmd), + output,stderr)) return output.strip() finally: if conf is not None: diff --git a/debian/changelog b/debian/changelog index c5e03d1b..56c20582 100644 --- a/debian/changelog +++ b/debian/changelog @@ -7,6 +7,9 @@ python-apt (0.8.7) UNRELEASED; urgency=low [ Jakub Wilk ] * Fix typos: the the -> the (closes: #679432) + [ Julian Andres Klode ] + * apt/auth.py: Do not merge stdout and stderr (Closes: #678706) + -- David Prévot Sat, 30 Jun 2012 16:50:03 -0400 python-apt (0.8.6) unstable; urgency=low -- cgit v1.2.3 From 33a8850f6463f6b96e03c475d37aaccb2a834129 Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Mon, 30 Jul 2012 13:28:19 +0200 Subject: apt/auth.py: Forward stderr from apt-key to our stderr if non-empty --- apt/auth.py | 4 ++++ debian/changelog | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'apt') diff --git a/apt/auth.py b/apt/auth.py index c52ec3a6..e088ae85 100644 --- a/apt/auth.py +++ b/apt/auth.py @@ -28,6 +28,7 @@ import atexit import os import os.path import subprocess +import sys import tempfile import apt_pkg @@ -83,6 +84,9 @@ def _call_apt_key_script(*args, **kwargs): "stdout: %s\n" "stderr: %s" % (proc.returncode, " ".join(cmd), output,stderr)) + elif stderr: + sys.stderr.write(stderr) # Forward stderr + return output.strip() finally: if conf is not None: diff --git a/debian/changelog b/debian/changelog index 56c20582..f908bcd1 100644 --- a/debian/changelog +++ b/debian/changelog @@ -8,7 +8,9 @@ python-apt (0.8.7) UNRELEASED; urgency=low * Fix typos: the the -> the (closes: #679432) [ Julian Andres Klode ] - * apt/auth.py: Do not merge stdout and stderr (Closes: #678706) + * apt/auth.py: + - Do not merge stdout and stderr (Closes: #678706) + - Forward stderr from apt-key to our stderr if non-empty -- David Prévot Sat, 30 Jun 2012 16:50:03 -0400 -- cgit v1.2.3