Replies: 1 comment 1 reply
-
There exist an ELLIPSE entity in the DXF file which has an invalid ratio. According to my research the ELLIPSE ratio must be in the range of 1e-6 to 1.0, otherwise AutoCAD will not open the DXF file.
EDIT: the |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Good day.
I open document (try DXF2018 and DXF2010/2013 formats, works same), delete some entities with paperspace.delete_entity(entity) and try to save document with doc.save() and got broken file and this:
`Traceback (most recent call last):
File "F:\Scipts\Delete\Delete.py", line 35, in
doc.save()
File "C:\Users\PyDev\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\ezdxf\document.py", line 543, in save
self.write(fp, fmt=fmt) # type: ignore
File "C:\Users\PyDev\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\ezdxf\document.py", line 601, in write
self.export_sections(tagwriter)
File "C:\Users\PyDev\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\ezdxf\document.py", line 620, in export_sections
self.entities.export_dxf(tagwriter)
File "C:\Users\PyDev\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\ezdxf\sections\entities.py", line 111, in export_dxf
layouts.modelspace().entity_space.export_dxf(tagwriter)
File "C:\Users\PyDev\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\ezdxf\entitydb.py", line 391, in export_dxf
entity.export_dxf(tagwriter)
File "C:\Users\PyDev\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\ezdxf\entities\dxfentity.py", line 686, in export_dxf
self.export_entity(tagwriter)
File "C:\Users\PyDev\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\ezdxf\entities\ellipse.py", line 126, in export_entity
assert is_valid_ratio(self.dxf.ratio)
AssertionError`
Overall, great package, big thanks.
Beta Was this translation helpful? Give feedback.
All reactions