hassanakbar4 / tractive-test

0 stars 0 forks source link

xml2rfc crash #366

Closed hassanakbar4 closed 3 years ago

hassanakbar4 commented 6 years ago

component_Version_3_cli_txt resolution_fixed type_defect | by miek@miek.nl


Not sure if this is the same thing as I saw earlier: stack trace:

Parsing file learninggo.xml
learninggo.xml(0): Warning: Invalid document before running preptool: Element li has extra content: t
Traceback (most recent call last):
  File "/usr/bin/xml2rfc", line 11, in <module>
    load_entry_point('xml2rfc==2.10.0', 'console_scripts', 'xml2rfc')()
  File "/usr/lib/python3/dist-packages/xml2rfc/run.py", line 382, in main
    xmlrfc.tree = prep.prep()
  File "/usr/lib/python3/dist-packages/xml2rfc/writers/preptool.py", line 353, in prep
    func(e, e.getparent())
  File "/usr/lib/python3/dist-packages/xml2rfc/writers/preptool.py", line 1124, in iref_add_number
    p.set('anchor', anchor)
  File "src/lxml/lxml.etree.pyx", line 824, in lxml.etree._Element.set (src/lxml/lxml.etree.c:51133)
  File "src/lxml/apihelpers.pxi", line 574, in lxml.etree._setAttributeValue (src/lxml/lxml.etree.c:22876)
  File "src/lxml/apihelpers.pxi", line 1441, in lxml.etree._utf8 (src/lxml/lxml.etree.c:31470)
TypeError: Argument must be bytes or unicode, got 'NoneType'

It doesn't barf out where in the doc this is.. and my XML file has 5000 lines. I'm attaching it anyway, maybe you have more luck than I.


Issue migrated from trac:366 at 2021-10-20 18:28:40 +0500

hassanakbar4 commented 6 years ago

@{"email"=>"miek@miek.nl", "name"=>nil, "username"=>nil} uploaded file learninggo.xml (182.3 KiB)

learninggo.xml

hassanakbar4 commented 6 years ago

@{"email"=>"henrik@levkowetz.com", "name"=>nil, "username"=>nil} changed status from new to closed

hassanakbar4 commented 6 years ago

@{"email"=>"henrik@levkowetz.com", "name"=>nil, "username"=>nil} changed resolution from ` tofixed`

hassanakbar4 commented 6 years ago

@{"email"=>"henrik@levkowetz.com", "name"=>nil, "username"=>nil} commented


Fixed in [2575]:

Fixed a couple of places where bad input could cause exceptions. Fixes issue #366.