svgslice and inkscape autodetection warning
SVGSlice is now working as an extension. If anyone is interested in getting this into inkscape's officially included extensions, would it be possible to do this for 42.1, or is that going to be bugfix-only?
There is one small Inkscape issue, which I'm currently working around.
I'm calling inkscape from within an extension, like so:
inkscape --without-gui --export-id="itemtoexport" --export-png="pngfilename" "svgfilename"
But this outputs the following:
** (inkscape:25789): WARNING **: Format autodetect failed. The file is being opened as SVG.
Strangely, this doesn't happen on the same file if I load it directly from the command line with inkscape "svgfilename".
At the moment, I'm redirecting the errors from the inkscape call to /dev/null, since inkscape will display the warnings as an extension failure. However, I'd prefer not to have to do this, in case inkscape DOES have something important to warn about.
Is this something I can prevent, or a bug that can be fixed for 42.1 somehow, regardless of whether the extension can make that release?
Lee Braiden wrote:
There is one small Inkscape issue, which I'm currently working around.
I'm calling inkscape from within an extension, like so:
inkscape --without-gui --export-id="itemtoexport" --export-png="pngfilename" "svgfilename"
But this outputs the following:
** (inkscape:25789): WARNING **: Format autodetect failed. The file is being opened as SVG.
Strangely, this doesn't happen on the same file if I load it directly from the command line with inkscape "svgfilename".
Are the filenames the same or does one have ".svg" on the end of it? The file detection being refered to here is all filename based.
--Ted
Ted Gould wrote:
Lee Braiden wrote:
There is one small Inkscape issue, which I'm currently working around.
I'm calling inkscape from within an extension, like so:
inkscape --without-gui --export-id="itemtoexport" --export-png="pngfilename" "svgfilename"
But this outputs the following:
** (inkscape:25789): WARNING **: Format autodetect failed. The file is being opened as SVG.
Strangely, this doesn't happen on the same file if I load it directly from the command line with inkscape "svgfilename".
Are the filenames the same or does one have ".svg" on the end of it? The file detection being refered to here is all filename based.
Ted this is our problem. The temp files saved by inkscape for effects do not have the *.svg extension.
Aaron Spike
On Sat, 2005-07-30 at 14:14 -0500, aaron@...749... wrote:
Ted this is our problem. The temp files saved by inkscape for effects do not have the *.svg extension.
Unfortunately this seems to be a problem with the function that makes temporary files. It requires that the random characters be on the end of the description, so it can't be "ink_tempRANDOM.svg" it has to be "ink_tempRANDOM". If we just tacked ".svg" on the end we wouldn't be guaranteed that the file isn't there already.
I believe that there are security implications here, but mostly I just ask Peter. He shakes his head at me a couple times and says "let me help" :)
--Ted
On Saturday 30 July 2005 22:17, Ted Gould wrote:
Unfortunately this seems to be a problem with the function that makes temporary files. It requires that the random characters be on the end of the description, so it can't be "ink_tempRANDOM.svg" it has to be "ink_tempRANDOM". If we just tacked ".svg" on the end we wouldn't be guaranteed that the file isn't there already.
Python's tempfile¹ library has functions like mktemp which let you specify the extension you want for the file. Perhaps the algorithm could be borrowed, if none of the standard c/c++ libs provide a similar call.
¹ http://www.python.org/doc/2.0.1/lib/module-tempfile.html
On Thu, Jul 28, 2005 at 05:48:16PM +0100, Lee Braiden wrote:
SVGSlice is now working as an extension. If anyone is interested in getting this into inkscape's officially included extensions, would it be possible to do this for 42.1, or is that going to be bugfix-only?
0.42.1 will be bugfix-only, but we're planning on getting 0.43 out relatively quickly (about a month) so you won't need to wait too long, and that'll give time to do some additional testing/fixing.
Bryce
On Thu, 2005-07-28 at 10:19 -0700, Bryce Harrington wrote:
On Thu, Jul 28, 2005 at 05:48:16PM +0100, Lee Braiden wrote:
SVGSlice is now working as an extension. If anyone is interested in getting this into inkscape's officially included extensions, would it be possible to do this for 42.1, or is that going to be bugfix-only?
0.42.1 will be bugfix-only, but we're planning on getting 0.43 out relatively quickly (about a month) so you won't need to wait too long, and that'll give time to do some additional testing/fixing.
Lee, yeah, lets try to get this into .43...This could be one of the kingpin features to demo extensions for .43.
Man, I wanna make some extensions...
Jon
participants (5)
-
unknown@example.com
-
Bryce Harrington
-
Jon Phillips
-
Lee Braiden
-
Ted Gould