embed image script fails
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Inkscape |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
While attempting to embed images in and SVG recently I got this failure:
Traceback (most recent call last):
File "/usr/share/
e.affect()
File "/usr/share/
self.effect()
File "/usr/share/
self.
File "/usr/share/
self.
File "/usr/share/
if (xlink[
TypeError: 'NoneType' object is unsubscriptable
I had embedded several other documents made with the same template already, so I'm not sure if this relates to a specific image or image type, or some other problem.
This appears to be caused by the absence of an 'xlink:href' attribute on some 'image' element. The SVG specification requires the 'xlink:href' attribute, but I doubt that Inkscape enforces this (on 'image' elements that it didn't create itself), so the script ought to deal gracefully with the absence (e.g, by just ignoring 'image' elements that have no 'xlink:href' attribute).