]> git.phdru.name Git - bookmarks_db.git/commitdiff
Insert lxml-based parser at the beginning.
authorOleg Broytman <phd@phdru.name>
Fri, 13 Aug 2010 13:19:27 +0000 (13:19 +0000)
committerOleg Broytman <phd@phdru.name>
Fri, 13 Aug 2010 13:19:27 +0000 (13:19 +0000)
git-svn-id: file:///home/phd/archive/SVN/bookmarks_db/trunk@280 fdd5c36f-1aea-0310-aeeb-c58d7e2b6c23

Robots/parse_html.py

index bc9a8d4950fc2ae430a111c423c78c3a5c5755b9..5e8061c793e307b0fad3d1163bf3b122884d185c 100755 (executable)
@@ -12,6 +12,13 @@ DEFAULT_CHARSET = "cp1251" # Stupid default for Russian Cyrillic
 
 parsers = []
 
+try:
+   from parse_html_lxml import parse_html
+except ImportError:
+   pass
+else:
+    parsers.append(parse_html)
+
 try:
    import parse_html_beautifulsoup
    parse_html_beautifulsoup.DEFAULT_CHARSET = DEFAULT_CHARSET