Bug 630688

Summary: mapnik-python bindings register fonts incorrectly
Product: [Fedora] Fedora Reporter: Malcolm Tredinnick <malcolm.tredinnick>
Component: mapnikAssignee: Alex Lancaster <alex>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 13CC: alex, chris.brown
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: mapnik-0.7.1-6.fc13 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-10-19 07:16:22 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Malcolm Tredinnick 2010-09-06 18:07:12 UTC
Description of problem:
Fedora has changed the default mapnik-python bindings to not ship yet another copy of the Deja Vu fonts. However, the path used to search for TTF fonts to register hasn't been changed to ensure that system fonts (including Deja Vu!) are found. Hence, all examples and demo code breaks when trying to render a font.

Version-Release number of selected component (if applicable):

mapnik-python-0.7.0-1.fc13.x86_64

How reproducible: Always

Additional info:

A patch needs to be applied to /usr/lib64/python2.6/site-packages/mapnik/paths.py to change the fontscollectionpath variable. Changing it to

   fontscollectionpath = "/usr/share/fonts"

works smoothly on a default Fedora installation.

Right now, anybody using mapnik + python has to do something like

   import mapnik
   mapnik.register_fonts("/usr/share/fonts")

in our own scripts, but that doesn't solve the problem for third-party problems. This isn't an upstream bug, as Fedora has changed upstream to remove the font location that is normally searched.

Comment 1 Fedora Admin XMLRPC Client 2010-10-09 16:30:53 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 2 Alex Lancaster 2010-10-10 05:33:56 UTC
(In reply to comment #0)

> A patch needs to be applied to
> /usr/lib64/python2.6/site-packages/mapnik/paths.py to change the
> fontscollectionpath variable. Changing it to
> 
>    fontscollectionpath = "/usr/share/fonts"
> 
> works smoothly on a default Fedora installation.

This is fixed in mapnik 0.7.1.  Build for f13 on it's way soon.

Comment 3 Fedora Update System 2010-10-10 06:04:34 UTC
mapnik-0.7.1-6.fc13 has been submitted as an update for Fedora 13.
https://admin.fedoraproject.org/updates/mapnik-0.7.1-6.fc13

Comment 4 Fedora Update System 2010-10-11 19:22:32 UTC
mapnik-0.7.1-6.fc13 has been pushed to the Fedora 13 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update mapnik'.  You can provide feedback for this update here: https://admin.fedoraproject.org/updates/mapnik-0.7.1-6.fc13

Comment 5 Alex Lancaster 2010-10-15 21:27:15 UTC
Reporter: can you please test out the update in updates-testing mentioned above and provide feedback via:

https://admin.fedoraproject.org/updates/mapnik-0.7.1-6.fc13

i.e. "works for me" or otherwise?  Packages with more +1 karma points get pushed to stable faster. Thanks.

Comment 6 Fedora Update System 2010-10-19 07:16:18 UTC
mapnik-0.7.1-6.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.