Commit graph

113 commits

Author SHA1 Message Date
Eli Bendersky
bf8ab77f94 Update XMLParser.close documentation and fix formatting.
Using ``method`` markup because the method is on a callback object, not an
explicitly documented method. :meth: markup creates links within the current
class which is incorrect.

In addition, indent the paragraph correctly.
2013-08-25 15:27:36 -07:00
Ezio Melotti
74eba65fb6 Fix markup in elementtree docs. 2013-08-26 01:05:57 +03:00
Eli Bendersky
bfd78370a5 Clarify the documentation of XMLParser.close
The return value of close() is not always a toplevel element. It depends on
what the underlying target returns. By default, TreeBuilder returns the
toplevel document element.
2013-08-24 15:11:44 -07:00
Eli Bendersky
c4216ab92b Issue #17902: Clarify doc of ElementTree.iterparse and IncrementalParser
Based on patch by Aaron Oakley
2013-08-03 18:55:10 -07:00
Eli Bendersky
ca97fd3053 Issue #17902: Clarify doc of ElementTree.iterparse 2013-08-03 18:52:32 -07:00
Eli Bendersky
fb625448f8 Clarify docs too: events can be any sequence (not that the C code supports it) 2013-05-19 09:09:24 -07:00
Eli Bendersky
3bdead1113 Add some documentation for IncrementalParesr 2013-04-20 09:06:27 -07:00
Eli Bendersky
10e0af8493 Fix trailing whitespace 2013-04-20 05:54:29 -07:00
Eli Bendersky
ab2a76c8a8 Update ET documentation reprhasing the mention of the new IncrementalParser in
the doc for iterparse.
2013-04-20 05:53:50 -07:00
Antoine Pitrou
5b235d0923 Issue #17741: Add ElementTree.IncrementalParser, an event-driven parser for non-blocking applications. 2013-04-18 19:37:06 +02:00
Georg Brandl
1bab7134a8 Merge with 3.3. 2013-03-28 13:28:55 +01:00
Georg Brandl
44ea77bd81 Closes #4159: add LaTeX tabular column specifications to tables that otherwise are cut off or have overlapping text. 2013-03-28 13:28:44 +01:00
Christian Heimes
9869e60dc2 Issue 17538: Document XML vulnerabilties 2013-03-26 17:48:28 +01:00
Christian Heimes
768f6a5360 Issue 17538: Document XML vulnerabilties 2013-03-26 17:47:23 +01:00
Christian Heimes
7380a67267 Issue 17538: Document XML vulnerabilties 2013-03-26 17:35:55 +01:00
Eli Bendersky
7343cb0790 Issue #11367: fix documentation of some find* methods in ElementTree 2013-03-12 06:01:22 -07:00
Serhiy Storchaka
9e189f0a28 Cleanup the docs ElementTree a bit. 2013-01-13 22:24:27 +02:00
Serhiy Storchaka
f1b045f417 Describe the default_namespace parameter of ElemetTree.write. 2013-01-13 22:04:43 +02:00
Serhiy Storchaka
03530b980e Describe the default_namespace parameter of ElemetTree.write. 2013-01-13 21:58:04 +02:00
Eli Bendersky
e9af827fb1 Cleanup the docs ElementTree a bit and describe the default_namespace parameter. In the code, replace the old outdated Doxygen-ish comment above ElementTree.write by a proper docstring. 2013-01-13 06:27:51 -08:00
Eli Bendersky
a9a2ef5550 Close #14377: Add a new parameter to ElementTree.write and some module-level
serialization functions - short_empty_elements. It controls how elements
without contents are emitted.

Patch by Serhiy Storchaka. Feature initially proposed by Ariel Poliak.
2013-01-13 06:04:43 -08:00
Eli Bendersky
831893a68e Issue #16082: clarify the documentation of tostring[list] saying that it may generate a bytestring, depending on the given encoding. 2012-10-09 07:18:16 -07:00
Eli Bendersky
323a43af06 Issue #12322: clarify xpath reference for cases where the path reaches ancestors of the start element. Also add missing markup for a None. Thanks to patrick vrijlandt and Mike Hoy for the report and initial patches. 2012-10-09 06:46:33 -07:00
Eli Bendersky
a1b0f6d9be Issue #15586: fix prompts in some documentation examples 2012-08-18 05:42:22 +03:00
Eli Bendersky
3115f0d14b Issue #15586: typo fix. This commit is accompanied by an apology for all Liechtensteiners out there, and a thanks to Eric Araujo for noticing. 2012-08-15 14:26:30 +03:00
Eli Bendersky
0f4e934174 Issue #15586: add some examples to ElementTree documentation. Patch by Daniel Ellis. 2012-08-14 07:19:33 +03:00
Eli Bendersky
f96cf911a0 Issue #9458: clarify the documentation of ElementTree.write with regards to the type of the stream expected for a given encoding 2012-07-15 06:19:44 +03:00
Eli Bendersky
00f402bfcb Close #1767933: Badly formed XML using etree and utf-16. Patch by Serhiy Storchaka, with some minor fixes by me 2012-07-15 06:02:22 +03:00
Eli Bendersky
48c50bf4c8 Clarify ET.iterparse documentation - this function is not supported by the
C implementation.
2013-01-24 07:23:34 -08:00
Eli Bendersky
1bf239446f fix trailing whitespace 2012-06-01 07:15:00 +03:00
Eli Bendersky
52467b167e Issue #14007: make XMLParser a real subclassable type exported from _elementtree. +cleanups 2012-06-01 07:13:08 +03:00
Eli Bendersky
48d358ba86 Issue #14007: implemented the 'element_factory' feature of TreeBuilder in
_elementtree, with a test.
2012-05-30 17:57:50 +03:00
Eli Bendersky
737b173355 Issue 14814: Add namespaces keyword arg to find(*) methods in _elementtree.
Add attrib keyword to Element and SubElement in _elementtree.
Patch developed with Ezio Melotti.
2012-05-29 06:02:56 +03:00
Eli Bendersky
c1d9869cb9 Issue #14006: improve the documentation of xml.etree.ElementTree
Removed the useless explanation of the Element data structure that started the
documentation page. Instead, the documentation now starts with a brief tutorial
skimming some of the capabilities of the module. The tutorial can be followed
by additional topic-specific sections (such as XPath support), and eventually
by a reference that goes over the module's classes and functions, as usual.
2012-03-30 11:44:15 +03:00
Eli Bendersky
ede001a832 Fix doc typo noticed by Amaury Forgeot d'Arc 2012-03-27 04:57:23 +02:00
Eli Bendersky
3a4875e5e3 Issue #6488: Explain the XPath support of xml.etree.ElementTree, with code
samples and a reference. Also fix the other nits mentioned in the issue.

This also partially addresses issue #14006.
2012-03-26 20:43:32 +02:00
Eli Bendersky
396e8fcf36 Issue #13782: streamline argument type-checking in ET.Element
append, extend and insert now consistently type-check their argument in both
the C and Python implementations, and raise TypeError for non-Element
argument.

Added tests
2012-03-23 14:24:20 +02:00
Eli Bendersky
3405001491 Issue #9257: clarify the events iterparse accepts 2012-03-16 08:42:36 +02:00
Eli Bendersky
604c4ff43d Issue #9257: clarify the events iterparse accepts 2012-03-16 08:41:30 +02:00
Eli Bendersky
5b77d81314 Issue #14207: the ParseError exception raised by _elementtree was made
consistent to the one raised by the Python module (the 'code' attribute
was added).

In addition, the exception is now documented.

Added a test to check that ParseError has the required attributes, and
threw away the equivalent doctest which is no longer required.
2012-03-16 08:20:05 +02:00
Florent Xicluna
a72a98f24a Issue #13988: cElementTree is deprecated and the _elementtree accelerator is automatically used whenever available. 2012-02-13 11:03:30 +01:00
Ezio Melotti
138fc896c8 #13138: add missing versionadded. 2011-10-10 00:02:03 +03:00
Raymond Hettinger
3029affc85 Add missing source links. 2011-02-10 08:09:36 +00:00
Antoine Pitrou
11cb961b38 Add cross-references to the glossary entry for file objects. 2010-09-15 11:11:28 +00:00
Georg Brandl
67b21b7547 Consistency check for versionadded/changed directives. 2010-08-17 15:07:14 +00:00
Florent Xicluna
c17f17294f Issue #8047: Fix the xml.etree serializer to return bytes by default.
Use ``encoding="unicode"`` to generate a Unicode string.
2010-08-08 19:48:29 +00:00
Ezio Melotti
f8754a60a8 Update versionadded/changed. 2010-03-21 07:16:43 +00:00
Florent Xicluna
dddd5e9098 Merged revisions 78944 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r78944 | florent.xicluna | 2010-03-14 02:22:09 +0100 (dim, 14 mar 2010) | 2 lines

  Minor documentation updates for xml.etree.
........
2010-03-14 01:28:07 +00:00
Florent Xicluna
f15351d938 Merged revisions 78838-78839,78917,78919,78934,78937 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r78838 | florent.xicluna | 2010-03-11 15:36:19 +0100 (jeu, 11 mar 2010) | 2 lines

  Issue #6472: The xml.etree package is updated to ElementTree 1.3.  The cElementTree module is updated too.
........
  r78839 | florent.xicluna | 2010-03-11 16:55:11 +0100 (jeu, 11 mar 2010) | 2 lines

  Fix repr of tree Element on windows.
........
  r78917 | florent.xicluna | 2010-03-13 12:18:49 +0100 (sam, 13 mar 2010) | 2 lines

  Move the xml test data to their own directory.
........
  r78919 | florent.xicluna | 2010-03-13 13:41:48 +0100 (sam, 13 mar 2010) | 2 lines

  Do not chdir when running test_xml_etree, and enhance the findfile helper.
........
  r78934 | florent.xicluna | 2010-03-13 18:56:19 +0100 (sam, 13 mar 2010) | 2 lines

  Update some parts of the xml.etree documentation.
........
  r78937 | florent.xicluna | 2010-03-13 21:30:15 +0100 (sam, 13 mar 2010) | 3 lines

  Add the keyword argument "method=None" to the .write() method and the tostring/tostringlist functions.
  Update the function, class and method signatures, according to the new convention.
........
2010-03-13 23:24:31 +00:00
Georg Brandl
7f01a13e7c Last round of adapting style of documenting argument default values. 2009-09-16 15:58:14 +00:00