This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: etree: Add XPath documentation
Type: enhancement Stage: needs patch
Components: Documentation Versions: Python 3.2, Python 2.7
process
Status: closed Resolution: duplicate
Dependencies: Superseder: ElementTree documentation refers to "path" with no explanation, and inconsistently
View: 6488
Assigned To: Nosy List: BreamoreBoy, docs@python, flox, georg.brandl, guettli, littlemog, mbone
Priority: normal Keywords: easy, patch

Created on 2008-05-15 14:49 by guettli, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
xpath_examples.diff mbone, 2010-07-20 03:34
Messages (4)
msg66863 - (view) Author: Thomas Guettler (guettli) * Date: 2008-05-15 14:49
The current documentation of etree [1] does not explain the 
syntax of the supported xpaths.


[1] current documation:
http://docs.python.org/lib/elementtree-elementtree-objects.html

[2] ElementTree supported XPath:
http://effbot.org/zone/element-xpath.htm

It would be very nice to have some simple examples for myetree.find(xpath).
msg110015 - (view) Author: Mark Lawrence (BreamoreBoy) * Date: 2010-07-11 14:24
Shouldn't this be assigned to docs@python?
msg110857 - (view) Author: Matt Bone (mbone) Date: 2010-07-20 03:34
Here's a patch for 3.2 with some simple examples.  They're under the ElementTree findall method.  Maybe there should be similar examples for Element's find/findall methods?
msg113344 - (view) Author: Florent Xicluna (flox) * (Python committer) Date: 2010-08-08 22:22
There's another issue about lack of documentation on this topic.
See #6488.
History
Date User Action Args
2022-04-11 14:56:34adminsetgithub: 47113
2010-08-08 22:22:24floxsetstatus: open -> closed
resolution: duplicate
messages: + msg113344

assignee: docs@python ->
superseder: ElementTree documentation refers to "path" with no explanation, and inconsistently
2010-07-25 10:10:13BreamoreBoysetassignee: effbot -> docs@python

nosy: - effbot
2010-07-20 03:34:47mbonesetfiles: + xpath_examples.diff

nosy: + mbone
messages: + msg110857

keywords: + patch
2010-07-11 14:28:57ezio.melottisetnosy: + docs@python

stage: needs patch
2010-07-11 14:24:43BreamoreBoysetnosy: + BreamoreBoy
messages: + msg110015
2010-02-27 12:34:19littlemogsetnosy: + littlemog
2010-02-19 22:59:59floxsetnosy: + effbot, flox
versions: + Python 2.7, Python 3.2
priority: normal
assignee: georg.brandl -> effbot
keywords: + easy
2008-05-15 14:49:49guettlicreate