summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPablo Galindo <Pablogsal@gmail.com>2017-10-16 09:24:22 +0100
committerSerhiy Storchaka <storchaka@gmail.com>2017-10-16 11:24:22 +0300
commit0df19055c92a0b0728659807978e4ca4d6c8e1bc (patch)
tree2a699db98ad6085ba9f92e595be62c8ad65fa395
parent676db4bbf2e7c18dc7c35add17dd3bbdc2d3eeb3 (diff)
downloadcpython-git-0df19055c92a0b0728659807978e4ca4d6c8e1bc.tar.gz
bpo-31776: Missing "raise from None" in Lib/xml/etree/ElementPath.py (#3978)
-rw-r--r--Lib/xml/etree/ElementPath.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/xml/etree/ElementPath.py b/Lib/xml/etree/ElementPath.py
index c9d6ef345b..ef32917b14 100644
--- a/Lib/xml/etree/ElementPath.py
+++ b/Lib/xml/etree/ElementPath.py
@@ -285,7 +285,7 @@ def iterfind(elem, path, namespaces=None):
try:
selector.append(ops[token[0]](next, token))
except StopIteration:
- raise SyntaxError("invalid path")
+ raise SyntaxError("invalid path") from None
try:
token = next()
if token[0] == "/":