diff options
author | Berker Peksag <berker.peksag@gmail.com> | 2016-06-10 20:00:52 (GMT) |
---|---|---|
committer | Berker Peksag <berker.peksag@gmail.com> | 2016-06-10 20:00:52 (GMT) |
commit | 904a2ef2e20ad22d324da18a9c98cb65666babb8 (patch) | |
tree | 4fd0259310b09263c5c372a4e570d48b3873360b /Lib/distutils/command | |
parent | 87a8bcc221a6d3ca9a8d46838af5d0d21320e340 (diff) | |
download | cpython-904a2ef2e20ad22d324da18a9c98cb65666babb8.zip cpython-904a2ef2e20ad22d324da18a9c98cb65666babb8.tar.gz cpython-904a2ef2e20ad22d324da18a9c98cb65666babb8.tar.bz2 |
Issue #20900: distutils register command now decodes HTTP responses correctly
Initial patch by ingrid.
Diffstat (limited to 'Lib/distutils/command')
-rw-r--r-- | Lib/distutils/command/register.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/distutils/command/register.py b/Lib/distutils/command/register.py index b49f86f..86343c8 100644 --- a/Lib/distutils/command/register.py +++ b/Lib/distutils/command/register.py @@ -296,9 +296,9 @@ Your selection [default 1]: ''', log.INFO) result = 500, str(e) else: if self.show_response: - data = result.read() + data = self._read_pypi_response(result) result = 200, 'OK' if self.show_response: - dashes = '-' * 75 - self.announce('%s%r%s' % (dashes, data, dashes)) + msg = '\n'.join(('-' * 75, data, '-' * 75)) + self.announce(msg, log.INFO) return result |