質問

html5lib にそれが最新のリリース(0.11)はやや古いだと指摘しています。 Pythonの部分を使用して、私はnoreferrer">問題70 号59 の最近のを見つけることができません安定しているMercurialの改正ます。

最新の先端が良くない、私はpython setup.py installから、次のエラーを得ます:

byte-compiling build/bdist.linux-x86_64/egg/html5lib/treewalkers/_base.py to _base.pyc
  File "build/bdist.linux-x86_64/egg/html5lib/treewalkers/_base.py", line 40
    "data": []}
         ^
SyntaxError: invalid syntax

そして、私は、実行時に以下のエラーが出ます:

    soup = parser.parse(page.read())
  File "build/bdist.linux-x86_64/egg/html5lib/html5parser.py", line 165, in parse
  File "build/bdist.linux-x86_64/egg/html5lib/html5parser.py", line 144, in _parse
  File "build/bdist.linux-x86_64/egg/html5lib/html5parser.py", line 454, in processDoctype
TypeError: insertDoctype() takes exactly 4 arguments (2 given)

私はlxmlのとBeautifulSoupでのPython 2.5.2でそれを使用しています。

役に立ちましたか?

解決

2010年1月の時点で、それはバージョン0.90のように見えるあなたが欲しいものです。

http://code.google.com/p/html5lib/downloads/list

scroll top