classification
Title: expat binding for XML_ParserReset
Type: enhancement Stage: patch review
Components: Extension Modules, XML Versions: Python 3.5
process
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: amaury.forgeotdarc, christian.heimes, eikenberry, loewis, nnorwitz, zseil
Priority: normal Keywords: patch

Created on 2005-05-25 20:37 by eikenberry, last changed 2014-02-03 15:45 by BreamoreBoy.

Files
File name Uploaded Description Edit
pyexpat.patch eikenberry, 2005-05-31 06:10 Patch adding XML_ParserReset binding
Messages (8)
msg54535 - (view) Author: John Eikenberry (eikenberry) Date: 2005-05-25 20:37
XML_ParserReset is an expat parser method for resetting the parser to handle a new document. 

This keeps you from having to create a new parser for each document.

msg54536 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2005-05-30 08:37
Logged In: YES 
user_id=21627

Would you like to work on a patch for this feature? Exposing
more methods from Expat is a good idea.
msg54537 - (view) Author: John Eikenberry (eikenberry) Date: 2005-05-31 06:10
Logged In: YES 
user_id=322022

Ok. I gave it a whirl. The patch is attached. If you have a moment, could you please look over it and let me know if I made any mistakes.  Its a forward diff as recommended by the guidelines. I tried to follow them as much as possible.

Thanks.
msg54538 - (view) Author: John Eikenberry (eikenberry) Date: 2005-05-31 06:12
Logged In: YES 
user_id=322022

Forgot to mention I made the patch against current CVS.
msg54539 - (view) Author: Neal Norwitz (nnorwitz) * (Python committer) Date: 2005-10-01 03:44
Logged In: YES 
user_id=33168

See patch #1208730.
msg54540 - (view) Author: Ziga Seilnacht (zseil) * (Python committer) Date: 2006-04-07 15:40
Logged In: YES 
user_id=1326842

That is patch #1244208.
msg93786 - (view) Author: Amaury Forgeot d'Arc (amaury.forgeotdarc) * (Python committer) Date: 2009-10-09 12:11
This (old) patch needs some work:

- unit tests are neeeded.

- it it not enough to return NULL when XML_ParserReset() returns an
error; a python exception must be raised.

- "This function may not be used on a parser created using
XML_ExternalEntityParserCreate": if XML_ParserReset() does not check it
properly, we should ensure that an exception is properly raised.

- "How many of the struct elements do I need to reset?": this should be
worked out. And I'm not convinced that self->intern should be reset.
msg114994 - (view) Author: Mark Lawrence (BreamoreBoy) * Date: 2010-08-26 15:58
Anyone interested in updating the patch for 3.2?
History
Date User Action Args
2014-02-03 15:45:30BreamoreBoysetnosy: - BreamoreBoy
2013-11-20 16:50:37christian.heimessetassignee: christian.heimes ->
versions: + Python 3.5, - Python 3.4
2013-07-08 15:25:13christian.heimessetassignee: christian.heimes
stage: test needed -> patch review

nosy: + christian.heimes
versions: + Python 3.4, - Python 3.2
2010-08-26 15:58:04BreamoreBoysetnosy: + BreamoreBoy

messages: + msg114994
versions: + Python 3.2, - Python 3.1, Python 2.7
2009-10-09 12:11:30amaury.forgeotdarcsetnosy: + amaury.forgeotdarc
messages: + msg93786
2009-03-30 22:24:33ajaksu2setkeywords: + patch
stage: test needed
components: + XML
versions: + Python 3.1, Python 2.7
2009-03-30 22:24:03ajaksu2linkissue1244208 superseder
2009-03-30 22:24:03ajaksu2unlinkissue1244208 dependencies
2009-03-04 15:17:56ajaksu2linkissue1244208 dependencies
2005-05-25 20:37:55eikenberrycreate