Improve error message.

This commit is contained in:
Bastian Kleineidam 2013-02-20 20:51:15 +01:00
parent 91c32515d5
commit 6d04ef7abd
2 changed files with 2 additions and 2 deletions

2
dosage
View file

@ -70,7 +70,7 @@ def saveComicStrip(strip, basepath):
if saved:
allskipped = False
except IOError as msg:
out.error('Could not save %s: %s' % (image.filename, msg))
out.error('Could not save image at %s to %s: %s' % (image.referrer, image.filename, msg))
errors += 1
return errors, allskipped

View file

@ -77,7 +77,7 @@ class _ComicTester(TestCase):
try:
image.save(self.tmpdir)
except Exception as msg:
self.check(False, 'could not save %s to %s: %s' % (image.url, self.tmpdir, msg))
self.check(False, 'could not save %s at %s to %s: %s' % (image.url, image.referrer, self.tmpdir, msg))
def check(self, condition, msg):
self.assertTrue(condition, "%s %s %s" % (self.name, self.url, msg))