[Checkins] SVN: zopyx.convert2/trunk/ relaed check for images
Andreas Jung
andreas at andreas-jung.com
Fri Feb 19 10:44:15 EST 2010
Log message for revision 109160:
relaed check for images
Changed:
U zopyx.convert2/trunk/CHANGES.txt
U zopyx.convert2/trunk/setup.py
U zopyx.convert2/trunk/src/zopyx/convert2/tidy.py
-=-
Modified: zopyx.convert2/trunk/CHANGES.txt
===================================================================
--- zopyx.convert2/trunk/CHANGES.txt 2010-02-19 13:43:14 UTC (rev 109159)
+++ zopyx.convert2/trunk/CHANGES.txt 2010-02-19 15:44:15 UTC (rev 109160)
@@ -1,3 +1,7 @@
+2.1.1 (2010-02-19)
+==================
+- relaxed tidy check for existence of images
+
2.1.0 (2009-09-05)
==================
- Calibre integration
Modified: zopyx.convert2/trunk/setup.py
===================================================================
--- zopyx.convert2/trunk/setup.py 2010-02-19 13:43:14 UTC (rev 109159)
+++ zopyx.convert2/trunk/setup.py 2010-02-19 15:44:15 UTC (rev 109160)
@@ -12,7 +12,7 @@
'Programming Language :: Python',
]
-version = '2.1.0'
+version = '2.1.1'
desc = unicode(file('README.txt').read().strip(), 'utf-8')
changes = file('CHANGES.txt').read().strip()
Modified: zopyx.convert2/trunk/src/zopyx/convert2/tidy.py
===================================================================
--- zopyx.convert2/trunk/src/zopyx/convert2/tidy.py 2010-02-19 13:43:14 UTC (rev 109159)
+++ zopyx.convert2/trunk/src/zopyx/convert2/tidy.py 2010-02-19 15:44:15 UTC (rev 109160)
@@ -6,11 +6,14 @@
import os
import re
+import logging
from util import newTempfile
from htmlentitydefs import name2codepoint
from BeautifulSoup import BeautifulSoup
+LOG = logging.getLogger('zopyx.convert2')
+
def tidyhtml(filename, encoding='utf-8'):
html = file(filename, 'rb').read()
@@ -30,7 +33,7 @@
if os.path.exists(possible_img):
img['src'] = possible_img
else:
- raise IOError('No image file found: %s' % src)
+ LOG.warn('No image file found: %s' % src)
html = soup.renderContents()
More information about the checkins
mailing list