Error appending inspected linked element for detailed meshes #5415

Was resulting in error below for meshes with > 1000 face indices (>~333 tris)

last_error: Traceback (most recent call last):
  File "C:\Users\Ryan Schultz\AppData\Roaming\Blender Foundation\Blender\4.2\extensions\.local\lib\python3.11\site-packages\bonsai\bim\ifc.py", line 408, in execute_ifc_operator
    result = getattr(operator, "_execute")(context)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\Ryan Schultz\AppData\Roaming\Blender Foundation\Blender\4.2\extensions\.local\lib\python3.11\site-packages\bonsai\bim\module\project\operator.py", line 1858, in _execute
    ifc_file = ifcopenshell.open(queried_obj["ifc_filepath"])
                                 ~~~~~~~~~~~^^^^^^^^^^^^^^^^
KeyError: 'bpy_struct[key]: key "ifc_filepath" not found'
This commit is contained in:
Andrej730
2024-10-14 17:18:43 +05:00
parent 686514b88a
commit 79c09ae225
@@ -1754,6 +1754,7 @@ class LoadLinkedProject(bpy.types.Operator):
obj["guids"] = [shape.guid]
obj["guid_ids"] = [len(mesh.polygons)]
obj["db"] = self.db_filepath
obj["ifc_filepath"] = self.filepath
self.collection.objects.link(obj)