fixup zip exception in open_zip

Review Request #107 — Created March 14, 2014 and discarded

dturner-tw
commons
pants-reviews
jsirois, lahosken
we expect that time is monotonic, but not necessarily strictly increasing


In open_zip, fixup exception to include the name of the failing file
This is a twofer because I wanted to actually have a passing test-suite before requesting a review.  But actually there is another unrelated failing test (which I will look at on Monday).

Anyway, the new test passes, as do all of the old ones that passed prior.
DT
LA
  1. I admit I have no idea what args[0] is gonna say there. But if you claim this is a more-useful error message, I believe you :-)
    1. Sorry to be late to the party, but +1 - Larry's confusion points to problems.  This is a bit detailed and e.message is deprecated in 2.7+, how about just treat the exception type as opaque and raise zipfile.BadZipfile('Could not open zip file @ %s: %s' % (path, e)) - or some wording.
    2. (fixed -- anything else I can improve?)
  2. 
      
DT
LA
  1. 
      
  2. yay this makes sense to me and I'm no Professor Python
  3. 
      
DT
Review request changed

Status: Discarded

Change Summary:

Closing as discarded because I didn't see this checked in and its been idle for some time. Feel free to reopen.
Loading...