summaryrefslogtreecommitdiff
path: root/sphinx/util/nodes.py
diff options
context:
space:
mode:
Diffstat (limited to 'sphinx/util/nodes.py')
-rw-r--r--sphinx/util/nodes.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/sphinx/util/nodes.py b/sphinx/util/nodes.py
index 52e43c2e2..53b4d056e 100644
--- a/sphinx/util/nodes.py
+++ b/sphinx/util/nodes.py
@@ -148,7 +148,7 @@ def apply_source_workaround(node: Element) -> None:
logger.debug('[i18n] PATCH: %r to have rawsource: %s',
get_full_module_name(node), repr_domxml(node))
# strip classifier from rawsource of term
- for classifier in reversed(node.parent.traverse(nodes.classifier)):
+ for classifier in reversed(list(node.parent.traverse(nodes.classifier))):
node.rawsource = re.sub(r'\s*:\s*%s' % re.escape(classifier.astext()),
'', node.rawsource)