diff --git a/src/ifcopenshell-python/ifcopenshell/__init__.py b/src/ifcopenshell-python/ifcopenshell/__init__.py index 99b5b737cd..110a38c85b 100644 --- a/src/ifcopenshell-python/ifcopenshell/__init__.py +++ b/src/ifcopenshell-python/ifcopenshell/__init__.py @@ -156,6 +156,8 @@ def open( print(products[0] == model[122] == model["2XQ$n5SLP5MBLyL442paFx"]) # True """ path = Path(path) + if not path.exists(): + raise FileNotFoundError(f"File does not exist: '{path}'.") if format is None: format = guess_format(path) if format == ".ifcXML":