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.
Created on 2008年05月11日 13:32 by hanselda, last changed 2022年04月11日 14:56 by admin.
| Messages (1) | |||
|---|---|---|---|
| msg66628 - (view) | Author: Luyang Han (hanselda) | Date: 2008年05月11日 13:32 | |
when use xml.dom.pulldom module to parse a large xml file, if all the
information is saved in one xml file, the module can handle it in the
following way without construction the whole DOM:
events = xml.dom.pulldom.parse('file.xml')
for (event, node) in events:
process(event, node)
But if 'file.xml' contains some large external entities, for example:
<!ENTITY file_external SYSTEM "others.xml">
<body>&file_external;</body>
Then using the same python snippet above leads to enormous memory
usage. I did not perform a concrete benchmark, in one case a 3M
external xml file drained about 1 GB memory. I think in this case it
might be the whole DOM structure is constructed.
|
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:56:34 | admin | set | github: 47067 |
| 2019年05月28日 08:47:13 | Jeffrey.Kintscher | set | nosy:
+ Jeffrey.Kintscher |
| 2019年05月16日 01:09:38 | cheryl.sabella | set | nosy:
+ scoder versions: + Python 3.8, - Python 3.2, Python 3.3, Python 3.4 |
| 2014年03月07日 12:46:54 | mvolz | set | nosy:
+ mvolz |
| 2013年03月30日 22:51:28 | pitrou | set | nosy:
+ christian.heimes |
| 2012年11月09日 13:23:17 | ezio.melotti | set | stage: needs patch versions: + Python 3.3, Python 3.4, - Python 3.1 |
| 2010年06月09日 22:16:33 | terry.reedy | set | versions: + Python 3.1, Python 2.7, Python 3.2, - Python 2.5 |
| 2008年05月11日 13:32:17 | hanselda | create | |