Re: expat parsing error

2010-06-02 Thread kak...@gmail.com
On 2 Ιούν, 03:47, John Machin wrote: > On Jun 2, 1:57 am, "kak...@gmail.com" wrote: > > > > > > > On Jun 1, 11:12 am, "kak...@gmail.com" wrote: > > > > On Jun 1, 11:09 am, John Bokma wrote: > > > > > "kak...@gmail.com" writes: > > > > > On Jun 1, 10:34 am, Stefan Behnel wrote: > > > > >> kak.

Re: expat parsing error

2010-06-01 Thread John Machin
On Jun 2, 1:57 am, "kak...@gmail.com" wrote: > On Jun 1, 11:12 am, "kak...@gmail.com" wrote: > > > > > On Jun 1, 11:09 am, John Bokma wrote: > > > > "kak...@gmail.com" writes: > > > > On Jun 1, 10:34 am, Stefan Behnel wrote: > > > >> kak...@gmail.com, 01.06.2010 16:00: > > > > >> > how can i f

Re: expat parsing error

2010-06-01 Thread kak...@gmail.com
On Jun 1, 11:12 am, "kak...@gmail.com" wrote: > On Jun 1, 11:09 am, John Bokma wrote: > > > > > "kak...@gmail.com" writes: > > > On Jun 1, 10:34 am, Stefan Behnel wrote: > > >> kak...@gmail.com, 01.06.2010 16:00: > > > >> > how can i fix it, how to "ignore" the headers and parse only > > >> > t

Re: expat parsing error

2010-06-01 Thread kak...@gmail.com
On Jun 1, 11:09 am, John Bokma wrote: > "kak...@gmail.com" writes: > > On Jun 1, 10:34 am, Stefan Behnel wrote: > >> kak...@gmail.com, 01.06.2010 16:00: > > >> > how can i fix it, how to "ignore" the headers and parse only > >> > the XML? > > >> Consider reading the answers you got in the last t

Re: expat parsing error

2010-06-01 Thread John Bokma
"kak...@gmail.com" writes: > On Jun 1, 10:34 am, Stefan Behnel wrote: >> kak...@gmail.com, 01.06.2010 16:00: >> >> > how can i fix it, how to "ignore" the headers and parse only >> > the XML? >> >> Consider reading the answers you got in the last thread that you opened >> with exactly this quest

Re: expat parsing error

2010-06-01 Thread kak...@gmail.com
On Jun 1, 10:34 am, Stefan Behnel wrote: > kak...@gmail.com, 01.06.2010 16:00: > > > how can i fix it, how to "ignore" the headers and parse only > > the XML? > > Consider reading the answers you got in the last thread that you opened > with exactly this question. > > Stefan That's exactly, what

Re: expat parsing error

2010-06-01 Thread Stefan Behnel
kak...@gmail.com, 01.06.2010 16:00: how can i fix it, how to "ignore" the headers and parse only the XML? Consider reading the answers you got in the last thread that you opened with exactly this question. Stefan -- http://mail.python.org/mailman/listinfo/python-list

Re: expat parsing error

2010-06-01 Thread John Bokma
"kak...@gmail.com" writes: > On Jun 1, 9:51 am, John Bokma wrote: >> "kak...@gmail.com" writes: >> > I got the following error >> > --- --- >> >   File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux- >> > x86_64.egg/twisted/internet/selectreactor.py", line 146, in >> > _doReadOrW

Re: expat parsing error

2010-06-01 Thread kak...@gmail.com
On Jun 1, 9:51 am, John Bokma wrote: > "kak...@gmail.com" writes: > > I got the following error > > --- --- > >   File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux- > > x86_64.egg/twisted/internet/selectreactor.py", line 146, in > > _doReadOrWrite > >     why = getattr(selectable

Re: expat parsing error

2010-06-01 Thread John Bokma
"kak...@gmail.com" writes: > I got the following error > --- --- > File "/usr/lib/python2.6/site-packages/Twisted-10.0.0-py2.6-linux- > x86_64.egg/twisted/internet/selectreactor.py", line 146, in > _doReadOrWrite > why = getattr(selectable, method)() > File "/usr/lib/python2.6/site-packa

Re: expat having problems with entities (&)

2009-12-11 Thread nnguyen
On Dec 11, 4:39 pm, Rami Chowdhury wrote: > On Fri, Dec 11, 2009 at 13:23, nnguyen wrote: > > > Any ideas on any expat tricks I'm missing out on? I'm also inclined to > > try another parser that can keep the string together when there are > > entities, or at least ampersands. > > IIRC expat expli

Re: expat having problems with entities (&)

2009-12-11 Thread nnguyen
On Dec 11, 4:23 pm, nnguyen wrote: > I need expat to parse this block of xml: > > > c-P&P > LOT 3677 > (F) > > > I need to parse the xml and return a dictionary that follows roughly > the same layout as the xml. Currently the code for the class handling > this is: > > class XML2Map(): > >

Re: expat having problems with entities (&)

2009-12-11 Thread Rami Chowdhury
On Fri, Dec 11, 2009 at 13:23, nnguyen wrote: > > Any ideas on any expat tricks I'm missing out on? I'm also inclined to > try another parser that can keep the string together when there are > entities, or at least ampersands. IIRC expat explicitly does not guarantee that character data will be h

Re: expat error, help to debug?

2007-08-28 Thread Andreas Lobinger
Aloha, Andreas Lobinger wrote: > Andreas Lobinger wrote: >> Lawrence D'Oliveiro wrote: >>> In message <[EMAIL PROTECTED]>, Andreas Lobinger wrote: Anyone any idea where the error is produced? > The registered Handler has to return a (integer) value. > Would have been nice if this had been men

Re: expat error, help to debug?

2007-08-28 Thread Andreas Lobinger
Aloha, Andreas Lobinger wrote: > Lawrence D'Oliveiro wrote: >> In message <[EMAIL PROTECTED]>, Andreas Lobinger wrote: >>> Anyone any idea where the error is produced? ... to share my findings with you: def ex(self,context,baseid,n1,n2): print "x",context,n1,n2 return 1 T

Re: expat error, help to debug?

2007-08-27 Thread Andreas Lobinger
Aloha, Lawrence D'Oliveiro wrote: > In message <[EMAIL PROTECTED]>, Andreas Lobinger wrote: >>Anyone any idea where the error is produced? > Do you want to try adding an EndElementHandler as well, just to get more > information on where the error might be happening? I want. Adding an EndElement

Re: expat error, help to debug?

2007-08-26 Thread Lawrence D'Oliveiro
In message <[EMAIL PROTECTED]>, Andreas Lobinger wrote: > Anyone any idea where the error is produced? Do you want to try adding an EndElementHandler as well, just to get more information on where the error might be happening? -- http://mail.python.org/mailman/listinfo/python-list

Re: expat parser

2007-05-28 Thread Stefan Behnel
Sebastian Bassi wrote: > I have this code: > > import xml.parsers.expat > def start_element(name, attrs): >print 'Start element:', name, attrs > def end_element(name): >print 'End element:', name > def char_data(data): >print 'Character data:', repr(data) > p = xml.parsers.expat.Parser

Re: expat

2006-02-28 Thread Katja Suess
Merci à Frederik et Jarek! According to your hints I did tests with a different coding and another option in OpenOffice 'Size optimization for XML format'. Went fine! - Back to my files from yesterday the same proper converting... uups Anyway, it's running! Katja -- http://mail.python.org/mailman

Re: expat

2006-02-27 Thread Jarek Zgoda
Katja Suess napisał(a): > may I have a hint what the problem is in my situation? > Is it a syntax error in sweetone.odt or in xml.parsers.expat? > Same problem with different file instead of sweetone.odt means that it's > not the file that has a syntax error. > xml.parsers.expat is a standard modu

Re: expat

2006-02-27 Thread Fredrik Lundh
Katja Suess wrote: > may I have a hint what the problem is in my situation? > Is it a syntax error in sweetone.odt or in xml.parsers.expat? > xml.parsers.expat.ExpatError: syntax error: line 1, column 0 it's a problem with the file you're parsing (either because it's not a valid XML file, or bec

Re: Expat - how to UseForeignDTD

2005-10-20 Thread B Mahoney
I needed to set Entity Parsing, such as parser.SetParamEntityParsing( expat.XML_PARAM_ENTITY_PARSING_ALWAYS ) -- http://mail.python.org/mailman/listinfo/python-list