mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-25 09:32:37 +00:00
Update rule_executor.py
This commit is contained in:
@@ -92,7 +92,7 @@ def run(f, logger):
|
|||||||
current_dir_files = {fn.lower(): fn for fn in os.listdir('.')}
|
current_dir_files = {fn.lower(): fn for fn in os.listdir('.')}
|
||||||
schema_name = str(f.schema).split(' ')[-1].lower()
|
schema_name = str(f.schema).split(' ')[-1].lower()
|
||||||
schema_path = current_dir_files.get(schema_name + '.exp')
|
schema_path = current_dir_files.get(schema_name + '.exp')
|
||||||
fn = schema_name + '.py'
|
fn = schema_path[:-4] + '.py'
|
||||||
if not os.path.exists(fn):
|
if not os.path.exists(fn):
|
||||||
subprocess.run([sys.executable, "-m", "ifcopenshell.express.rule_compiler", schema_path, fn], check=True)
|
subprocess.run([sys.executable, "-m", "ifcopenshell.express.rule_compiler", schema_path, fn], check=True)
|
||||||
time.sleep(1.)
|
time.sleep(1.)
|
||||||
|
|||||||
Reference in New Issue
Block a user