From 22b7f56ce4943fe14647aa3d096fb3f0e72c43ed Mon Sep 17 00:00:00 2001 From: Richard Brice <37087370+RickBrice@users.noreply.github.com> Date: Sat, 29 Aug 2026 15:34:03 -0700 Subject: [PATCH] Fixes clearing of cache when opening subsequent files --- src/bonsai/bonsai/bim/ifc.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/bonsai/bonsai/bim/ifc.py b/src/bonsai/bonsai/bim/ifc.py index c5dfabf046..97dc78fe7b 100644 --- a/src/bonsai/bonsai/bim/ifc.py +++ b/src/bonsai/bonsai/bim/ifc.py @@ -125,6 +125,8 @@ class IfcStore: future: list[TransactionStep] = [] schema_identifiers = ["IFC4", "IFC2X3", "IFC4X3_ADD2"] session_files: dict[str, ifcopenshell.file] = {} + cache: Optional[ifcopenshell.geom.serializers.hdf5] = None + cache_path: str = "" @staticmethod def purge(): @@ -143,6 +145,8 @@ class IfcStore: IfcStore.future = [] IfcStore.schema_identifiers = ["IFC4", "IFC2X3", "IFC4X3_ADD2"] IfcStore.session_files = {} + IfcStore.cache = None + IfcStore.cache_path = "" @staticmethod def get_file() -> ifcopenshell.file | None: