[lxml-dev] Failing lxml.html tests
Ian Bicking
ianb at colorstudy.com
Fri Oct 26 17:03:48 CEST 2007
(I had sent this to Stefan, but maybe someone on the list will recognize
something about what's going on here)
Stefan Behnel wrote:
> Ian Bicking wrote:
>> When I run the tests just get a lot of these:
>>
>>
>> ======================================================================
>> ERROR: test_write_method_text
>> (lxml.tests.test_elementtree.ElementTreeTestCase)
>> ----------------------------------------------------------------------
>> Traceback (most recent call last):
>> File "unittest.py", line 260, in run
>> testMethod()
>> File "/home/ianb/src/lxml/src/lxml/tests/test_elementtree.py", line
>> 777, in test_write_method_text
>> tree.write(f, method="text")
>> TypeError: write() got an unexpected keyword argument 'method'
>>
>> ----------------------------------------------------------------------
>>
>>
>> I've deleted all the .c files and rebuilt, and I'm still getting these
>> exceptions. Do you know what that is from?
>
> Hmm, maybe you have easy_installed an older version of lxml? Setuptools plug
> eggs into the system before the PYTHONPATH, so test.py may not be able to
> import the correct version. The version output should tell you, though...
There were some other lxml eggs on the path, but I think the trunk was
above them since I'd just run "python setup.py develop". I tried python
setup.py install, just in case there was something weird about develop,
but same thing (either way it seems to be running out of the checkout,
so presumably test.py is fixing up the path somehow). Here's the
version information test.py gave:
webdev$ python test.py
TESTED VERSION: 2.0.alpha4-47900
Python: (2, 4, 4, 'candidate', 1)
lxml.etree: (2, 0, -196, 47900)
libxml used: (2, 6, 26)
libxml compiled: (2, 6, 26)
libxslt used: (1, 1, 17)
libxslt compiled: (1, 1, 17)
--
Ian Bicking : ianb at colorstudy.com : http://blog.ianbicking.org
More information about the lxml-dev
mailing list