Comment 16 for bug 386664

Revision history for this message
su_v (suv-lp) wrote : Re: [Bug 386664] Re: "Gather Resources" option for gathering fonts and images

thanks JazzyNico for your quick response! On Inkscape r21615, Mac OS X 10.5.7:
- valid archive: ok
- rel/abs path: ok
- included media files: ok
- xlink:href in created/resaved file: ok
- encoding: test handling of german umlauts in linked image filename? fail

inkscape displays the linked images with special characters in their
filenames correct. python extension fails when trying to resolve filename?

filename: 'upper-left-äöü.png' (pasted name from osx clipboard - I had
renamed 'upper-left.png' in the filemanager (Finder), where it displays as
'upper-left-äöü.png').

I don't know what encoding OS X uses with the clipboard, my default language
in OS X is set to 'en_US', the keyboard layout is 'de_CH'. The filename also
displays correct in the Terminal.app with bash, LANG='en_US.UTF8' and in the
X11/GTKfilechooser dialog of Inkscape (started from a shell with LANG="en_US").

extension error message:

Traceback (most recent call last):
  File "/Users/suv/.config/inkscape/extensions/svg_and_media_zip_output.py", line 122, in <module>
    e.affect()
  File "/Users/suv/Applications/Inkscape-21615.app/Contents/Resources/extensions/inkex.py", line 198, in affect
    self.effect()
  File "/Users/suv/.config/inkscape/extensions/svg_and_media_zip_output.py", line 80, in effect
    self.collectAndZipImages(node, docname, z)
  File "/Users/suv/.config/inkscape/extensions/svg_and_media_zip_output.py", line 107, in collectAndZipImages
    z.write(absref.encode("latin-1"),os.path.basename(absref).encode("latin-1"))
  File "/System/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/zipfile.py", line 541, in write
    st = os.stat(filename)
OSError: [Errno 2] No such file or directory: '/Volumes/blue/src/Inkscape/dev/launchpad/media_zip_output/img-de/upper-left-\xe4\xf6\xfc.png'

result: empty zip archive