Error on DXF exporting an (apparently) correct SVG file

Bug #1375196 reported by Yann Lossouarn
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Invalid
Undecided
Unassigned

Bug Description

Hello,

I loaded the attached file, that comes straight from from the VisiCut software (http://hci.rwth-aachen.de/visicut). AFAIK, it seems correct. However, when I use Inkscape 0.48 to make a DXF export of this file I get the following error :

'
'
Traceback (most recent call last):

  File "dxf_outlines.py", line 295, in <module>

    e.affect()

  File "D:\Program Files (x86)\Inkscape\share\extensions\inkex.py", line 221, in affect

    self.effect()

  File "dxf_outlines.py", line 278, in effect

    self.dxf_add(dxf_templates.r14_style)

AttributeError: 'module' object has no attribute 'r14_style'
'
'

Any idea?

Thanks,
Yann

Tags: dxf exporting svg
Revision history for this message
Yann Lossouarn (yann-lossouarn) wrote :
Revision history for this message
su_v (suv-lp) wrote :

Not reproduced on OS X 10.7.5 with
- Inkscape 0.48.2 and 0.48.5 (32bit, official packages)
- Inkscape 0.48.4 and 0.48.5 (64bit, local builds)
- Inkscape 0.91pre2 r13566 (64bit, local build)

Revision history for this message
su_v (suv-lp) wrote :

DXF file exported with current stable 0.48.5 (default DXF export settings)

Revision history for this message
Yann Lossouarn (yann-lossouarn) wrote :

I have Inkscape 0.48.5 r10040, Windows 7 Pro SP1. Just in case, can you describe the action sequence you followed to make your export?
I checked your DXF export, which does not really comply with the source SVG file (check the piece on the right, it has extra lines, and the scale is not good, but this probably another issue.

Revision history for this message
Yann Lossouarn (yann-lossouarn) wrote :

I tested on a Linux 0.48.3 r9886, the behaviour is different, I get the following error:

"Le fichier /bla/bla/Sheet1.dxf n'a pas pu être enregistré."
... which translates to something like:
"File /bla/bla/Sheet1.dxf could not be saved."

:/

Revision history for this message
su_v (suv-lp) wrote :

On 2014-09-29 14:45 , Yann Lossouarn wrote:
> Just in case, can you describe the action sequence you followed to
> make your export?

Steps to export DXF (Inkscape 0.48.5):
1) open the example SVG file
2) open 'File > Save a copy as ...'
3) choose "Desktop Cutting Plotter (AutoCAD DXF R14) (*.dxf)"
   as output format
4) optionally adjust file name
5) click on 'Save' button
6) in the new popup dialog "Desktop Cutting Plotter" click
   on 'OK' button

Default settings in the "Desktop Cutting Plotter" dialog:

[ ] use ROBO-Master type of spline output
[x] use LWPOLYLINE type of line output

Base unit: pt
Character Encoding: Latin 1

Revision history for this message
Yann Lossouarn (yann-lossouarn) wrote :

The only difference with the scenario I followed is the base unit (I used mm), but the bug also occurs when using pt... :/

Revision history for this message
su_v (suv-lp) wrote :

Do you test with the same file you attached to the report? The SVG file attached here was edited/saved in Inkscape at least once (i.e. is very unlikely the original SVG file generated by the referenced application)

Revision history for this message
su_v (suv-lp) wrote :

Not reproduced on Ubuntu 14.04 (VM, 64bit) with Inkscape 0.48.5 (from inkscape PPA), export with base units 'mm' attached.

Revision history for this message
Yann Lossouarn (yann-lossouarn) wrote :

Here are the SVG files, in the state I get it from VisiCut :

Revision history for this message
Alvin Penner (apenner) wrote :

using the file from comment 10, problem not reproduced on Inkscape 0.48.5, Windows 7 (32 bit). Result is attached here.
On my first pass I noticed a few objects were missing, text and circles. So I used the procedure Edit->Select All, and then Path->Object to Path. This gave a more complete output.
    Are you still encountering error messages? If so, you might want to check to see if the files are up to date. The relevant files are:

 Directory of C:\Program Files\Inkscape\share\extensions

02/09/2012 01:58 PM 2,404 dxf_outlines.inx
02/27/2014 11:16 PM 14,766 dxf_outlines.py
11/18/2010 02:14 PM 3,519 dxf_templates.py

They are also available at:
http://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/files/head:/share/extensions/

<offtopic>
I have to confess I am still a bit confused as to the precise origin of this file, it contains a lot of inkscape-specific references in it, despite the fact that it says that it was created by Corel Draw.
</offtopic>

Revision history for this message
su_v (suv-lp) wrote :

On 2014-10-03 18:52 , Alvin Penner wrote:
> They are also available at:
> http://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/files/head:/share/extensions/

Note that the link above is to trunk, not to the stable release branch.

For stable 0.48.5, the files are here:
http://bazaar.launchpad.net/~inkscape.dev/inkscape/RELEASE_0_48_BRANCH/files/head:/share/extensions/

Revision history for this message
Yann Lossouarn (yann-lossouarn) wrote :

I will make more tests next week. It appears the bug does not occur on my Linux (Ubuntu Trusty), so I was able to export these files to DXF files. I tried with "Better DXF output" and "Big Blue Saw" extensions, but none of these seem to work, and I had to manually transform everything to paths, insert lots of new nodes between nodes of every splines, and then transform segments into lines. As far as i understand, "Better DXF output" and "Big Blue Saw" aimed at embedding these actions into an automated export process, but they may not have been maintained, and did not survive Inkscape evolutions that occured in the meantime... :/ A shame, as DXF output is apparently the only common file format with Corel, which is the reference software for running laser cutters. I'd really love to find a solution to let users of our fablab use Inkscape without having to worry about paths, splines, nodes, etc. Any hope ?

Revision history for this message
Alvin Penner (apenner) wrote :

>> It appears the bug does not occur on my Linux (Ubuntu Trusty),

um, if the bug does not appear on Linux, then I would suggest comparing your Linux files to your Windows files. Under normal circumstances I believe they should be the same. You only need to look at the above 3 files, .inx and .py for starters. Your original comment suggested that the file dxf_templates.py is probably obsolete.

Revision history for this message
Alvin Penner (apenner) wrote :

also, I should probably warn you that if you are experimenting with extensions like "Better DXF output" then you need to be very careful to back up your original dxf Python files before you do this, because it is quite possible that some of these extensions may overwrite some of your existing Inkscape dxf files. At least these three files should be backed up just in case:

02/09/2012 01:58 PM 2,404 dxf_outlines.inx
 02/27/2014 11:16 PM 14,766 dxf_outlines.py
 11/18/2010 02:14 PM 3,519 dxf_templates.py

Revision history for this message
su_v (suv-lp) wrote :

Had you been able to fix the reported issue by restoring all files which possibly got replaced by when installing custom output extensions "Better DXF output" or "Big Blue Saw" on the affected computers?

[ IIRC at least one of these custom and outdated DXF output extension also overwrites one of the shared python modules shipped with Inkscape (used by other extensions too) with a modified version based on a much older Inkscape release. ]

Changed in inkscape:
status: New → Incomplete
Revision history for this message
su_v (suv-lp) wrote :

Closing - no further feedback provided by the reporter (most likely cause of the reported issue was a partially broken local installation on the affected system).

Changed in inkscape:
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.