Skip to content

Commit 7a568ff

Browse files
pythongh-93607: document root attribute of iterparse
1 parent 7e3f09c commit 7a568ff

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Doc/library/xml.etree.elementtree.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -628,6 +628,9 @@ Functions
628628
for applications where blocking reads can't be made. For fully non-blocking
629629
parsing, see :class:`XMLPullParser`.
630630

631+
Once *source* is fully read, the returned :term:`iterator` object is populated with a ``root``
632+
attribute which references to the root element of the resulting XML tree.
633+
631634
.. note::
632635

633636
:func:`iterparse` only guarantees that it has seen the ">" character of a

0 commit comments

Comments
 (0)