fnp
/
redakcja.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fixes
[redakcja.git]
/
src
/
catalogue
/
models
/
image.py
diff --git
a/src/catalogue/models/image.py
b/src/catalogue/models/image.py
index
34f61f9
..
8cadcec
100755
(executable)
--- a/
src/catalogue/models/image.py
+++ b/
src/catalogue/models/image.py
@@
-38,7
+38,7
@@
class Image(dvcs_models.Document):
# Representing
# ============
# Representing
# ============
- def __
unicode
__(self):
+ def __
str
__(self):
return self.title
@models.permalink
return self.title
@models.permalink
@@
-81,11
+81,11
@@
class Image(dvcs_models.Document):
picture = WLPicture.from_bytes(
picture_xml.encode('utf-8'),
image_store=SelfImageStore)
picture = WLPicture.from_bytes(
picture_xml.encode('utf-8'),
image_store=SelfImageStore)
- except ParseError
,
e:
+ except ParseError
as
e:
raise AssertionError(_('Invalid XML') + ': ' + str(e))
except NoDublinCore:
raise AssertionError(_('No Dublin Core found.'))
raise AssertionError(_('Invalid XML') + ': ' + str(e))
except NoDublinCore:
raise AssertionError(_('No Dublin Core found.'))
- except ValidationError
,
e:
+ except ValidationError
as
e:
raise AssertionError(_('Invalid Dublin Core') + ': ' + str(e))
valid_about = self.correct_about()
raise AssertionError(_('Invalid Dublin Core') + ': ' + str(e))
valid_about = self.correct_about()
@@
-95,7
+95,7
@@
class Image(dvcs_models.Document):
def publishable_error(self):
try:
return self.assert_publishable()
def publishable_error(self):
try:
return self.assert_publishable()
- except AssertionError
,
e:
+ except AssertionError
as
e:
return e
else:
return None
return e
else:
return None