Bug 820533 - xhtml2pdf does not support languages other than Latin1
xhtml2pdf does not support languages other than Latin1
Status: CLOSED EOL
Product: Fedora
Classification: Fedora
Component: python-xhtml2pdf (Show other bugs)
22
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Major Hayden
Fedora Extras Quality Assurance
: Reopened
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-05-10 06:18 EDT by Pavel Alexeev
Modified: 2016-07-19 06:05 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-07-19 06:05:35 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
File to reproduce problem (38 bytes, text/plain)
2012-05-14 05:12 EDT, Pavel Alexeev
no flags Details
pdf produced from attachment? (2.19 KB, application/pdf)
2012-05-14 05:42 EDT, Matthias Runge
no flags Details
Screenshot (81.16 KB, image/png)
2012-05-16 13:15 EDT, Pavel Alexeev
no flags Details

  None (edit)
Description Pavel Alexeev 2012-05-10 06:18:16 EDT
Description of problem:
In pdf it produce only bold squares instead of any letter not in Latin1 (tested on Russian).
--encoding option does nothing.

Version-Release number of selected component (if applicable):
$ rpm -qf `which xhtml2pdf`
python-xhtml2pdf-0.0.3-3.fc17.noarch

How reproducible:
Always.
Comment 1 Matthias Runge 2012-05-10 06:24:39 EDT
Do you have some snippet, to reproduce that? (My keyboard contains only latin characters...)

Thanks
Comment 2 Pavel Alexeev 2012-05-14 05:12:17 EDT
Created attachment 584300 [details]
File to reproduce problem

I've attach file to reproduce problem.
Comment 3 Matthias Runge 2012-05-14 05:41:31 EDT
your attachment doesn't look very cyrillic for me.

OK, my terminal is utf-8, I got your attachment from bz. 
I used my test-code:
from xhtml2pdf import pisa

def helloWorld():
	filebase = 'test'
	handle=open(filebase+'.html','ro')
	pdf = pisa.CreatePDF(handle.read(), file(filebase+'.pdf','wb'))

if __name__ == '__main__':
	pisa.showLogging()
	helloWorld()

(and test.html):
[mrunge@mrungexp ~]$ cat test.html 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
		  </head>
		  <body>
		  English text<br />
Русский текст
</body>
</html>
(produces the attached test.pdf)
Comment 4 Matthias Runge 2012-05-14 05:42:25 EDT
Created attachment 584304 [details]
pdf produced from attachment?
Comment 5 Matthias Runge 2012-05-14 05:49:50 EDT
The produced test.pdf looks for me exactly the same as the code from attachment https://bugzilla.redhat.com/attachment.cgi?id=584300 but also not as cyrillic as I' expect your contribution.
Comment 6 Pavel Alexeev 2012-05-16 13:15:10 EDT
Created attachment 585023 [details]
Screenshot

Please look at screenshot as I seen it.
Comment 7 Matthias Runge 2012-05-16 16:08:29 EDT
Ok, understood, finally, I can reproduce this; it looks like those font shapes don't exist to in that font rendering the PDF. 

Let's wait and see what upstream answers.
Comment 8 Fedora End Of Life 2013-07-03 21:09:53 EDT
This message is a reminder that Fedora 17 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 17. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '17'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 17's end of life.

Bug Reporter:  Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 17 is end of life. If you 
would still like  to see this bug fixed and are able to reproduce it 
against a later version  of Fedora, you are encouraged  change the 
'version' to a later Fedora version prior to Fedora 17's end of life.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.
Comment 9 Fedora Admin XMLRPC Client 2015-07-03 03:03:31 EDT
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.
Comment 10 Fedora Admin XMLRPC Client 2015-07-12 00:24:59 EDT
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.
Comment 11 Major Hayden 2015-07-12 00:33:25 EDT
Just took over this package.  Is the issue still present in version 0.0.6?
Comment 12 Jan Kurik 2015-07-15 11:09:18 EDT
This bug appears to have been reported against 'rawhide' during the Fedora 23 development cycle.
Changing version to '23'.

(As we did not run this process for some time, it could affect also pre-Fedora 23 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 23 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora23
Comment 13 Pavel Alexeev 2015-10-04 13:32:29 EDT
Unfortunately I can't even test it now:

$ xhtml2pdf pdf.input
****************************************************
IMPORT ERROR!
Reportlab Version 2.1+ is needed!
****************************************************

The following Python packages are required for PISA:
- Reportlab Toolkit >= 2.2 <http://www.reportlab.org/>
- HTML5lib >= 0.11.1 <http://code.google.com/p/html5lib/>

Optional packages:
- pyPDF <http://pybrary.net/pyPdf/>
- PIL <http://www.pythonware.com/products/pil/>

No handlers could be found for logger "xhtml2pdf"
Traceback (most recent call last):
  File "/bin/xhtml2pdf", line 9, in <module>
    load_entry_point('xhtml2pdf==0.0.5', 'console_scripts', 'xhtml2pdf')()
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 558, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2682, in load_entry_point
    return ep.load()
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2355, in load
    return self.resolve()
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2361, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "/usr/lib/python2.7/site-packages/xhtml2pdf/__init__.py", line 41, in <module>
    from xhtml2pdf.util import REPORTLAB22
  File "/usr/lib/python2.7/site-packages/xhtml2pdf/util.py", line 39, in <module>
    raise ImportError("Reportlab Version 2.1+ is needed!")
ImportError: Reportlab Version 2.1+ is needed!


So problem actual.
Comment 14 Fedora End Of Life 2016-07-19 06:05:35 EDT
Fedora 22 changed to end-of-life (EOL) status on 2016-07-19. Fedora 22 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

Note You need to log in before you can comment on or make changes to this bug.