Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ifcopenshell-python segfaults when creating geometry (several versions affected) #904

Closed
haraldg opened this issue Jun 19, 2020 · 3 comments

Comments

@haraldg
Copy link
Contributor

haraldg commented Jun 19, 2020

Here is the example file: https://friends.ccbib.org/lambda/segfault.ifc
I tried to produce a minimal file, that only contains the offensive instance, but then it works fine. It's one of those bugs ... :-(

Here is the transcript to reproduce:

Python 3.8.3 (default, May 14 2020, 11:03:12) 
[GCC 9.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import ifcopenshell
>>> from ifcopenshell import geom
>>> f = ifcopenshell.open("segfault.ifc")
>>> settings = ifcopenshell.geom.settings()
>>> cr = ifcopenshell.geom.create_shape(settings,f[2513103])
Speicherzugriffsfehler

I have tried precompiled versions from the website and a local build of 8962e3b.

@aothms
Copy link
Member

aothms commented Jun 20, 2020

Yes, can confirm, appears to be an error calculating edge length of a bspline curve edge during boolean operation preprocessing. I'll have a look, might not be easy.

@aothms
Copy link
Member

aothms commented Jul 19, 2020

See discussion at #914 this is easily fixed by detecting this is a IFC4 Reference view with precalculated boolean subtractions

@Moult
Copy link
Contributor

Moult commented Sep 3, 2022

Tested with latest IfcOpenShell-python and all geometry is created fine without any segfaults :)

@Moult Moult closed this as completed Sep 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants