[Python-checkins] cpython: Fix UnboundLocalError in a finally block of one packaging test

eric.araujo python-checkins at python.org
Tue Jun 7 17:32:04 CEST 2011


http://hg.python.org/cpython/rev/e0534a0846ca
changeset:   70707:e0534a0846ca
user:        Éric Araujo <merwok at netwok.org>
date:        Mon Jun 06 22:24:19 2011 +0200
summary:
  Fix UnboundLocalError in a finally block of one packaging test

files:
  Lib/packaging/tests/test_command_upload.py |  2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)


diff --git a/Lib/packaging/tests/test_command_upload.py b/Lib/packaging/tests/test_command_upload.py
--- a/Lib/packaging/tests/test_command_upload.py
+++ b/Lib/packaging/tests/test_command_upload.py
@@ -140,8 +140,8 @@
         cmd.upload_docs = True
         cmd.ensure_finalized()
         cmd.repository = self.pypi.full_address
+        prev_dir = os.getcwd()
         try:
-            prev_dir = os.getcwd()
             os.chdir(self.tmp_dir)
             cmd.run()
         finally:

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list