[twill] Converting interactive session to code
Jamal.Mazrui at fcc.gov
Fri Feb 12 16:28:07 PST 2010
I found the line that was causing twill not to get a form object. It is
line 183 in what I think is the latest feedparser.py module.
Apparently, this line changes a variable in the sgmllib module with the
sgmllib.endbracket = EndBracketMatch()
It happens that this change causes twill parsing to fail on the page in
my example, even though it did not affect other pages where I was also
using forms. So, the problem was not actually related to how I imported
twill in the py2exe executable. It occurred because that executable
also imported feedparser, whereas my test script for debugging did not.
If I comment out the above line, twill works as expected. I do not know
what side effects that may cause. If anyone has suggestions for getting
the full functionality of feedparser without this side effect, plese let
More information about the twill