dquangsinh / fb2pdf

Automatically exported from code.google.com/p/fb2pdf
0 stars 0 forks source link

conversion failed around description/author_name #15

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
2007-03-06 01:16:59,680 DEBUG    Downloading
'http://s3.amazonaws.com/fb2pdf/6eaf159360d4abf5b8380caba6f97783.fb2' to
file
'kompyuterra_kompyuterra_676_jurnal_kompyuterra_n_8_ot_27_fevralya_2007_goda.fb2
'.
2007-03-06 01:17:30,517 DEBUG    Converting to TeX
2007-03-06 01:17:31,406 ERROR    Conversion Failed
Traceback (most recent call last):
  File "/sw/bin/fbdaemon", line 197, in processDocument
    fb2tex.fb2tex(fbfilename, texfilename)
  File "/sw/lib/python2.4/site-packages/fb2pdf/fb2tex.py", line 206, in fb2tex
    processDescription(fb.find("description"), f)
  File "/sw/lib/python2.4/site-packages/fb2pdf/fb2tex.py", line 501, in
processDescription
    author_name = authorName(a)
  File "/sw/lib/python2.4/site-packages/fb2pdf/fb2tex.py", line 461, in
authorName
    author_name = _text(fn)
  File "/sw/lib/python2.4/site-packages/fb2pdf/fb2tex.py", line 127, in _text
    return string.join([convXMLentities(e) for e in  t.contents])
  File "/sw/lib/python2.4/site-packages/fb2pdf/fb2tex.py", line 115, in
convXMLentities
    return s.replace('&lt;','<') \
TypeError: 'NoneType' object is not callable

Original issue reported on code.google.com by kroko...@gmail.com on 6 Mar 2007 at 5:32

GoogleCodeExporter commented 8 years ago
this document has buch of self-closing tags. Our parser does not get it.

Original comment by kroko...@gmail.com on 6 Mar 2007 at 6:11

GoogleCodeExporter commented 8 years ago
fixed by switching to MINIDOM.
BeautifulSoup (short BS) is really BS when it comes to XML parsing :)

Original comment by kroko...@gmail.com on 8 Mar 2007 at 4:51

GoogleCodeExporter commented 8 years ago
closing

Original comment by kroko...@gmail.com on 8 Mar 2007 at 4:51