Hello,

There’s a bit of related discussion here:

    
https://stackoverflow.com/questions/45642168/avoid-parsing-huge-xml-element-with-lxml
    
https://stackoverflow.com/questions/30708873/what-is-the-length-of-maximum-text-inside-an-xml-node
    https://github.com/sparklemotion/nokogiri/issues/740

So, basically my code generated an XML with nodes whose texts seems to blow 
past some limitation:

    lxml.etree.XMLSyntaxError: xmlSAX2Characters: huge text node, line 1755, 
column 10001255

Interestingly, the XML validates fine using the --huge option:

    xmllint --huge --noout --xinclude --nofixup-base-uris --schema test.xsd 
test.xml

Now I’m curious about two aspects here:

1) What actually is that current limitation on the size of nodes imposed by 
libxml2?

2) Assuming there is some flexibility with libxml2, what options does lxml 
offer to deal with huge text nodes?

Much thanks!
Jens

--
Jens Tröger
https://savage.light-speed.de/

_______________________________________________
lxml - The Python XML Toolkit mailing list -- lxml@python.org
To unsubscribe send an email to lxml-le...@python.org
https://mail.python.org/mailman3/lists/lxml.python.org/
Member address: arch...@mail-archive.com
  • [lxml] Max length of node ... Jens Tröger via lxml - The Python XML Toolkit

Reply via email to