Summary: | dev-python/mechanize-0.2.5 fails tests (AssertionError: 'comment' != 'decl') | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Paweł Hajdan, Jr. (RETIRED) <phajdan.jr> |
Component: | [OLD] Development | Assignee: | Python Gentoo Team <python> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | gentoo |
Priority: | Normal | Keywords: | TESTFAILURE |
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
URL: | https://github.com/jjlee/mechanize/issues/66 | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | build.log.gz |
Description
Paweł Hajdan, Jr. (RETIRED)
2012-06-07 09:22:01 UTC
This is indeed a test fail. In both, the call to p.get_token() is evaluated to 'comment'. 'comment' == <!-- && a 'decl' == <! It's fooled by the first char being a lower case. hmm. This is not a mechanize issue, it's a python issue, a Cpython2.7 issue. I tested mechanize some months ago in bug 397383 focusing on pyypy and it passed fine with python2.7. Now it fails with the bumped python-2.7.3. Re-emerged python-2.7.2, and lo and behold; archtester mechanize # USE_PYTHON="2.6 2.7" ebuild mechanize-0.2.5.ebuild clean test * Testing of dev-python/mechanize-0.2.5 with CPython 2.6... .................................................................................. Ran 541 tests in 6.099s OK (skipped=37) * Testing of dev-python/mechanize-0.2.5 with CPython 2.7... .................................................................................. Ran 540 tests in 5.102s OK (skipped=37) again passes in python2.7 Nice find. Can you isolate what change in Python caused the test failure? (In reply to comment #3) > Nice find. Can you isolate what change in Python caused the test failure? http://hg.python.org/cpython/rev/333e3acf2008 Cool. Do we have an upstream bug yet? Also, we might want to update the mechanize bug in the URL with the findings so far. (In reply to comment #5) > Cool. Do we have an upstream bug yet? It would be worth checking how <!foo> is treated by w3 standard to know if it's regression in HTMLParser or bug in mechanize that is relying on previous, invalid behavior of the parser. Just to know where to submit bug ;) strooth. A year has passed. I suppose I migrate this with the test failures still in place given no other option on a second glance, upstream is looking very dead. The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0b5e7f9e1dd85629427fe01b2379a1d70e1dc6d9 commit 0b5e7f9e1dd85629427fe01b2379a1d70e1dc6d9 Author: Patrice Clement <monsieurp@gentoo.org> AuthorDate: 2018-08-23 14:00:15 +0000 Commit: Patrice Clement <monsieurp@gentoo.org> CommitDate: 2018-08-23 14:00:25 +0000 dev-python/mechanize: version bump to 0.3.6. Bug: https://bugs.gentoo.org/420051 Package-Manager: Portage-2.3.40, Repoman-2.3.9 dev-python/mechanize/Manifest | 1 + dev-python/mechanize/mechanize-0.3.6.ebuild | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+) Please use the latest version. Tests do not fail with it. |