From 9d42f4c1eee7fc5ed928f3ec3a8416ae76d529c7 Mon Sep 17 00:00:00 2001 From: Bruno Postle Date: Thu, 2 Apr 2026 07:54:20 +0100 Subject: [PATCH] Update Bonsai to latest ifcmerge (#7581 #3096) This version has some functional differences: - Structured JSON error message instead of free text (on STDOUT not STDERR) - New --prioritise-local flag to control which side wins in merge conflicts (not used by Bonsai yet) - IfcLocalPlacement conflicts now auto-resolve instead of failing the merge (partial solution to #6885) - Float values are normalised when comparing entities (workaround for #7696) --- src/bonsai/Makefile | 6 +++--- src/bonsai/bonsai/tool/ifcgit.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/bonsai/Makefile b/src/bonsai/Makefile index 60ed304532..b517bc572b 100644 --- a/src/bonsai/Makefile +++ b/src/bonsai/Makefile @@ -64,6 +64,7 @@ PYNUMBER:=3$(PYMINOR) PYPI_VERSION:=3.$(PYMINOR) endif # def PYVERSION +IFCMERGE_VERSION:=2026-04-02 ifdef PLATFORM SUPPORTED_PLATFORMS := linux macos macosm1 win @@ -240,10 +241,9 @@ endif # required for three-way git merging ifeq ($(PLATFORM), win) - cd build/bonsai/libs/bin && wget https://github.com/brunopostle/ifcmerge/releases/download/2025-01-26/ifcmerge.zip - cd build/bonsai/libs/bin && unzip ifcmerge.zip && rm ifcmerge.zip + cd build/bonsai/libs/bin && wget https://github.com/brunopostle/ifcmerge/releases/download/$(IFCMERGE_VERSION)/ifcmerge.exe else - cd build/bonsai/libs/bin && wget https://raw.githubusercontent.com/brunopostle/ifcmerge/main/ifcmerge && chmod +x ifcmerge + cd build/bonsai/libs/bin && wget https://raw.githubusercontent.com/brunopostle/ifcmerge/$(IFCMERGE_VERSION)/ifcmerge && chmod +x ifcmerge endif # Generate translations module for Bonsai build diff --git a/src/bonsai/bonsai/tool/ifcgit.py b/src/bonsai/bonsai/tool/ifcgit.py index afff9fa3dc..1843716f58 100644 --- a/src/bonsai/bonsai/tool/ifcgit.py +++ b/src/bonsai/bonsai/tool/ifcgit.py @@ -546,7 +546,7 @@ class IfcGit: repo.git.mergetool(tool=mergetool) return None except git.exc.GitCommandError as exc: - return re.sub("( stderr: '|')", "", exc.stderr) + return re.sub("( stdout: '|')", "", exc.stdout) @classmethod def git_merge_abort(cls) -> None: