GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — xml.dom.minidom: Node.normalize() is quadratic in the number of adjacent text nodes · Issue #158860 · python/cpython Open Labels performancePerformance or resource usagePerformance or resource usagestdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytopic-XMLtype-featureA feature request or enhancementA feature request or enhancement Description
from xml.dom.minidom import Document doc = Document() root = doc.appendChild(doc.createElement('r')) for _ in range(32_000): root.appendChild(doc.createTextNode('x' * 48)) root.normalize() # ~450 ms; 8k nodes ~25 ms, 16k ~95 ms The parsers already merge character data, so you only hit this with documents built through the DOM API (appendChild/createTextNode, etc.). Fix: collect the pieces for each run and Linked PRsActivity
MetadataMetadataAssigneesLabelsperformancePerformance or resource usagePerformance or resource usagestdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytopic-XMLtype-featureA feature request or enhancementA feature request or enhancement ProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |