Subject: [xml2rfc] #229: No errors, no error messages, no output

From: "xml2rfc issue tracker" <[email-masked]>
Date: Wed, 05 Feb 2014 00:46:11 -0000

#229: No errors, no error messages, no output

 Hi.  I don't know if this is related to #225 or not.  If it is, it may add
 more information.   If not there is something about the online version
 that isn't working well for me and/or my templates.

 Under 2.4.5 (online at xml.resource.org), the attached file yields no
 error messages and a zero-length output file.   Under the "old CGI
 version" (http://xml.resource.org/old.html) with "strict DTD check" and
 the Windows GUI version (core version 2.3.5, GUI 0.8.0), no error messages
 but the output file is generated without problems.

-- 
-------------------------------+----------------------------------
 Reporter:  [email-masked]  |      Owner:  [email-masked]
     Type:  defect             |     Status:  new
 Priority:  medium             |  Milestone:
Component:  Version 2 cli      |    Version:  2.4.x
 Keywords:                     |
-------------------------------+----------------------------------

Ticket URL: <http://trac.tools.ietf.org/tools/xml2rfc/trac/ticket/229>
xml2rfc <http://tools.ietf.org/tools/xml2rfc/>

---

From: Henrik Levkowetz <[email-masked]>
Date: Wed, 05 Feb 2014 19:25:48 +0100

Hi John,

>  but the output file is generated without problems.

I can confirm there's a bug in xml2rfc 2.4.5 which is triggered by this
input file.

However, there also seems to be some trouble either at your end or in some
specific part of the online service:

If I go to xml.resource.org, click the 'Browse ...' button to select a file
to upload, select your enclosed file, and click the 'Submit' button without
changing any of the defaults in the form, I get a clear error message in the
top pane of the results page (see copy below).

How are you invoking the online service?  Browser brand and version, and
option selection in the 'Convert Your XML Source' submission form?

Best regards,

	Henrik

--------

Generating Text output in ASCII format
Expanding internal references and generating Text

Using XML_LIBRARY=/home/www/tools.ietf.org/tools/xml2rfc/web/public/rfc/bibxml:/home/www/tools.ietf.org/tools/xml2rfc/web/public/rfc/bibxml2:/home/www/tools.ietf.org/tools/xml2rfc/web/public/rfc/bibxml3:/home/www/tools.ietf.org/tools/xml2rfc/web/public/rfc/bibxml4:/home/www/tools.ietf.org/tools/xml2rfc/web/public/rfc/bibxml5
Parsing file INPUT
Resolving entity... /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc2629.dtd
Resolving entity... /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc2629-xhtml.ent
Resolving entity... /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc2629-other.ent
Resolving entity... /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc2629.dtd
Resolving entity... /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc2629-xhtml.ent
Resolving entity... /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc2629-other.ent
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.2026.xml
Loaded from cache reference.RFC.2026.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml
Loaded from cache reference.RFC.2119.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.6410.xml
Loaded from cache reference.RFC.6410.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.1058.xml
Loaded from cache reference.RFC.1058.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.1083.xml
Loaded from cache reference.RFC.1083.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.1145.xml
Loaded from cache reference.RFC.1145.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.1240.xml
Loaded from cache reference.RFC.1240.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.1421.xml
Loaded from cache reference.RFC.1421.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.1923.xml
Loaded from cache reference.RFC.1923.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.2556.xml
Loaded from cache reference.RFC.2556.xml
Resolving entity... http://xml.resource.org/public/rfc/bibxml/reference.RFC.4156.xml
Loaded from cache reference.RFC.4156.xml

Traceback (most recent call last):
  File "/usr/local/bin/xml2rfc", line 225, in <module>
    main()
  File "/usr/local/bin/xml2rfc", line 210, in main
    pagedwriter.write(filename)
  File "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.py", line 1150, in write
    self._build_index()
  File "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.py", line 969, in _build_index
    self.write_section_rec(middle, None)
  File "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.py", line 841, in write_section_rec
    level=level + 1, appendix=appendix)
  File "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.py", line 841, in write_section_rec
    level=level + 1, appendix=appendix)
  File "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.py", line 816, in write_section_rec
    self.write_t_rec(element, autoAnchor=autoAnchor)
  File "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/raw_txt.py", line 579, in write_t_rec
    inline_text, remainder = self._combine_inline_elements(remainder)
  File "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/raw_txt.py", line 442, in _combine_inline_elements
    line.append('[[' + anchor + element.text + source + ']]')
TypeError: cannot concatenate 'str' and 'NoneType' objects

--------

---

From: John C Klensin <[email-masked]>
Date: Wed, 05 Feb 2014 14:43:36 -0500

--On Wednesday, February 05, 2014 19:25 +0100 Henrik Levkowetz
<[email-masked]> wrote:

>> # 229: No errors, no error messages, no output
>> 
>>  Hi.  I don't know if this is related to #225 or not.  If it
>>  is, it may add more information.   If not there is something
>>  about the online version that isn't working well for me
>>  and/or my templates.
>> 
>>  Under 2.4.5 (online at xml.resource.org), the attached file
>>  yields no error messages and a zero-length output file.
>>  Under the "old CGI version"
>>  (http://xml.resource.org/old.html) with "strict DTD check"
>>  and the Windows GUI version (core version 2.3.5, GUI 0.8.0),
>>  no error messages but the output file is generated without
>>  problems.
> 
> I can confirm there's a bug in xml2rfc 2.4.5 which is
> triggered by this input file.
> 
> However, there also seems to be some trouble either at your
> end or in some specific part of the online service:
> 
> If I go to xml.resource.org, click the 'Browse ...' button to
> select a file to upload, select your enclosed file, and click
> the 'Submit' button without changing any of the defaults in
> the form, I get a clear error message in the top pane of the
> results page (see copy below).
> 
> How are you invoking the online service?  Browser brand and
> version, and option selection in the 'Convert Your XML Source'
> submission form?

First, Firefox 26.0, Windows 7 Pro 64.

I get the following:

With options set to "Plaintext" and "output result: file", the
_only_ thing I see is the "open with/ save as" popup showing a
zero-length file.

With options set to "Plaintext" and "output result: Use
frames...", I get output very similar (possibly identical) to
what you show below, but I have no clue as to what it means, the
messages seems to be about lines in the Python source, and
"cannot concatenate 'str' and 'NoneType' objects" means
approximately nothing to me (well, I know what it means, but I
can't do anything with it).  

Then I see a line that says "The file is not there -- check for
error messages or you may have clicked reload" which is both
useless (i.e., it doesn't give me a hint as to what to do next)
and misleading (the file I submitted _is_ "there" and there has
been no reload or similar action).  On a "user friendly" scale,
that message is possibly worse than Marshall's rather
distinctive "you lose" -- the latter at least doesn't lead to
any expectation that information is being provided.

I wish I could figure out how to be more constructive about this
(just complaining feels very uncomfortable), but the development
efforts haven't asked for UI design input or QA assistance
(things I do know about), my Python is nearly non-existent, and
I haven't written what I consider production-quality code in 20+
years.  Suggestions welcome, otherwise I'll keep whining until
you tell me to stop.

best regards and thanks for all the effort on this,
    john

> Using
> XML_LIBRARY=/home/www/tools.ietf.org/tools/xml2rfc/web/public/
> rfc/bibxml:/home/www/tools.ietf.org/tools/xml2rfc/web/public/r
> fc/bibxml2:/home/www/tools.ietf.org/tools/xml2rfc/web/public/r
> fc/bibxml3:/home/www/tools.ietf.org/tools/xml2rfc/web/public/r
> fc/bibxml4:/home/www/tools.ietf.org/tools/xml2rfc/web/public/r
> fc/bibxml5 Parsing file INPUT
> Resolving entity...
> /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc26
> 29.dtd Resolving entity...
> /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc26
> 29-xhtml.ent Resolving entity...
> /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc26
> 29-other.ent Resolving entity...
> /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc26
> 29.dtd Resolving entity...
> /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc26
> 29-xhtml.ent Resolving entity...
> /usr/local/lib/python2.7/dist-packages/xml2rfc/templates/rfc26
> 29-other.ent Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.2026.x
> ml Loaded from cache reference.RFC.2026.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.x
> ml Loaded from cache reference.RFC.2119.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.6410.x
> ml Loaded from cache reference.RFC.6410.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.1058.x
> ml Loaded from cache reference.RFC.1058.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.1083.x
> ml Loaded from cache reference.RFC.1083.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.1145.x
> ml Loaded from cache reference.RFC.1145.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.1240.x
> ml Loaded from cache reference.RFC.1240.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.1421.x
> ml Loaded from cache reference.RFC.1421.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.1923.x
> ml Loaded from cache reference.RFC.1923.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.2556.x
> ml Loaded from cache reference.RFC.2556.xml
> Resolving entity...
> http://xml.resource.org/public/rfc/bibxml/reference.RFC.4156.x
> ml Loaded from cache reference.RFC.4156.xml
> 
>   File
> "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.p
> y", line 1150, in write     self._build_index()
>   File
> "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.p
> y", line 969, in _build_index
>   File
> "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.p
> y", line 841, in write_section_rec     level=level + 1,
> appendix=appendix)
>   File
> "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.p
> y", line 841, in write_section_rec     level=level + 1,
> appendix=appendix)
>   File
> "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/base.p
> y", line 816, in write_section_rec
>   File
> "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/raw_tx
> t.py", line 579, in write_t_rec     inline_text, remainder =
> self._combine_inline_elements(remainder)   File
> "/usr/local/lib/python2.7/dist-packages/xml2rfc/writers/raw_tx
> t.py", line 442, in _combine_inline_elements