[Python-checkins] r65696 - doctools/trunk/sphinx/environment.py

georg.brandl python-checkins at python.org
Fri Aug 15 21:16:21 CEST 2008


Author: georg.brandl
Date: Fri Aug 15 21:16:20 2008
New Revision: 65696

Log:
Use alternate method of removing node from doctree which
doesn't raise assertion errors. :)


Modified:
   doctools/trunk/sphinx/environment.py

Modified: doctools/trunk/sphinx/environment.py
==============================================================================
--- doctools/trunk/sphinx/environment.py	(original)
+++ doctools/trunk/sphinx/environment.py	Fri Aug 15 21:16:20 2008
@@ -540,7 +540,7 @@
         filterlevel = self.config.keep_warnings and 2 or 5
         for node in doctree.traverse(nodes.system_message):
             if node['level'] < filterlevel:
-                node.replace_self([])
+                node.parent.remove(node)
 
     def process_dependencies(self, docname, doctree):
         """


More information about the Python-checkins mailing list