[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: well-formedness error
On Sat, 19 Jun 2004 18:51:39 +0200, Danny Ayers <danny666@xxxxxxxxxxx> wrote:
> Mark, of the feed-consumer applications which use your 'Universal'
> parser, what proportion provide some signal that a feed isn't valid XML?
I assume you mean "well-formed XML", but anyway, I have no idea. As a
library developer, all I can do is provide a clear and unambiguous
signal when the feed is not well-formed.
http://feedparser.org/docs/bozo.html
This includes parsing the feed with the proper character encoding,
which includes respecting RFC 3023.
http://feedparser.org/docs/character-encoding.html
As you can see, if the bozo bit comes back 1, the feed is not
well-formed, and bozo_exception includes the reason. If
bozo_exception is CharacterEncodingOverride, then the
non-wellformedness is a result of the feed failing to conform to RFC
3023.
What end-user applications do with that information is entirely up to
them. I can't force *my* users (developers using my library to build
other applications) to be draconian, or tolerant. All I can do is
give them accurate information.
--
Cheers,
-Mark