En Wed, 23 Jan 2008 14:06:10 -0200, Arne <[EMAIL PROTECTED]> escribió:
> On Jan 21, 11:25 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> > wrote: >> > On 21 Jan, 19:15, Bruno Desthuilliers <bruno. >> > [EMAIL PROTECTED]> wrote: >> >> >> This should not prevent you from learning how to properly parse XML >> >> (hint: with an XML parser). XML is *not* a line-oriented format, so >> you >> >> just can't get nowhere trying to parse it this way. >> >> Try ElementTree instead; there is an implementation included with >> Python > > This look very interesting! But it looks like that no documents is > well-formed! I've tried several RSS-feeds, but they are eighter > "undefined entity" or "not well-formed". This is not how it should be, > right? :) Well, the RSS feed "should" be valid XML... Try a more forgiving parser like BeautifulStone, or preprocess the input with Tidy or a similar program before feeding it to ElementTree. -- Gabriel Genellina -- http://mail.python.org/mailman/listinfo/python-list