summaryrefslogtreecommitdiff
path: root/Lib/distutils/command/upload.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/distutils/command/upload.py')
-rw-r--r--Lib/distutils/command/upload.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/distutils/command/upload.py b/Lib/distutils/command/upload.py
index 980cf68d06..d0133353a6 100644
--- a/Lib/distutils/command/upload.py
+++ b/Lib/distutils/command/upload.py
@@ -176,6 +176,9 @@ class upload(PyPIRCCommand):
result = urlopen(request)
status = result.getcode()
reason = result.msg
+ if self.show_response:
+ msg = '\n'.join(('-' * 75, r.read(), '-' * 75))
+ self.announce(msg, log.INFO)
except socket.error, e:
self.announce(str(e), log.ERROR)
return
@@ -189,6 +192,3 @@ class upload(PyPIRCCommand):
else:
self.announce('Upload failed (%s): %s' % (status, reason),
log.ERROR)
- if self.show_response:
- msg = '\n'.join(('-' * 75, r.read(), '-' * 75))
- self.announce(msg, log.INFO)