[twill] BeautifulSoup conflicts

twill.overbored@spamgourmet.com twill.overbored at spamgourmet.com
Sun Jul 2 20:20:10 PDT 2006


On 7/2/06, William K. Volkman - wkvsf at users.sourceforge.net
<>
wrote:
> Hi,
> On Sun, 2006-07-02 at 18:11, twill.overbored at spamgourmet.com wrote:
> > I'm trying to use both twill and BeautifulSoup. I downloaded the
> > latest BeautifulSoup (3.0.3) and have the following simple program:
> >
> > from BeautifulSoup import BeautifulSoup
>
> I suspect you're stepping on twill's desire to use BeautifulSoup,
> the quick and dirty solution solution would be:
>
> from BeautifulSoup import BeautifulSoup as MySoup

I had already tried this, but it still doesn't work; there's something
more intricate going on.

>
> A closer look at the twill documentation might reveal a way
> to get a BeautifulSoup object from twill directly...

The problem is that I'm trying to use code which seems to only work
with bsoup 3.x.

>
> > from twill.commands import *
> > from twill.errors import *
> > from twill import *
> > from sys import *
> > go('http://youtube.com/')
> > follow( 'Log In' )
> >
> > This raises a hard-to-decipher exception. Once I remove the
> > BeautifulSoup improt, everything's fine. Should this be filed as a
> > twill bug? Any workarounds in the meantime? Thanks in advance.
>
> HTH,
> William.
>
>



More information about the twill mailing list