[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2012-03-15 Thread Eli Bendersky
Changes by Eli Bendersky : -- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed ___ Python tracker ___

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2012-03-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset 84e4d76bd146 by Eli Bendersky in branch '3.2': Issue #9257: clarify the events iterparse accepts http://hg.python.org/cpython/rev/84e4d76bd146 New changeset 00c7142ee54a by Eli Bendersky in branch 'default': Issue #9257: clarify the events iterpars

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2012-02-10 Thread Eric Talevich
Eric Talevich added the comment: Well, this is not the best month for me to try digging into a new codebase... I would not mind if someone else did the patch for this. -- ___ Python tracker ___

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2012-02-08 Thread Eli Bendersky
Eli Bendersky added the comment: Changing the target version(s) and adding some documentation experts to the nosy list -- nosy: +eric.araujo, ezio.melotti, sandro.tosi versions: +Python 3.2, Python 3.3 -Python 3.1 ___ Python tracker

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2012-02-08 Thread Eli Bendersky
Eli Bendersky added the comment: Eric, Thanks for checking. I agree that this behavior is acceptable, but a documentation fix would be appropriate. The documentation of iterparse should mention the events it accepts, also saying that those are strings. The events are listed at http://effbot

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2012-02-08 Thread Eric Talevich
Eric Talevich added the comment: It's more-or-less fixed in Python 3.2: - With cElementTree, both bytes and strings are accepted for events; - With ElementTree, only strings are accepted, and bytes raise a ValueError (unknown event). A small inconsistency remains, but it's fine to just use

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2012-02-07 Thread Eli Bendersky
Eli Bendersky added the comment: At this point, 3.1 won't be fixed with such changes any longer. Is this fixed in 3.2/3.3? -- nosy: +eli.bendersky ___ Python tracker ___ ___

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2011-11-08 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +flox type: -> behavior ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2011-01-18 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.o

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2011-01-14 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: r78942 is quite large unfortunately. But just patching _elementree.c::xmlparser_setevents() should be possible. This would at least fix the "invalid event tuple" error. -- ___ Python tracker

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2011-01-14 Thread Peter
Peter added the comment: This wasn't fixed in Python 3.1.3 either. Is the trunk commit Amaury identified from py3k branch (r78942) suitable to back port to Python 3.1.x? -- ___ Python tracker

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2010-08-16 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: No, apparently, r78942 was not included in 3.1.2. -- ___ Python tracker ___ ___ Python-bugs-li

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2010-08-12 Thread Eric Talevich
Eric Talevich added the comment: This bug seems to be still present in Python 3.1.2. (Unless I'm doing something wrong.) Was r78942 included in the 3.1.2 release? -- ___ Python tracker

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2010-07-23 Thread Peter
Changes by Peter : -- nosy: +maubp ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailma

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2010-07-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: It seems that this has been fixed in the py3k branch (r78942). Now both bytes and unicode are accepted. Can someone check? -- nosy: +amaury.forgeotdarc stage: -> needs patch ___ Python tracker

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2010-07-13 Thread Eric Talevich
New submission from Eric Talevich : In xml.etree, ElementTree and cElementTree implement different interfaces for the iterparse function/class. In ElementTree, the argument "events" must be a tuple of strings: from xml.etree import ElementTree as ET for result in ET.iterparse('example.xml', ev