Skip to content

Commit 35f209c

Browse files
committed
[core] Split version name on the correct separator
In adbdd3b, the version name for develop versions has been updated to use the "+" separator instead of "-". When loading a scene that has been saved since this change, errors occur during the parsing of the version name as the "+" is not expected. This commit fixes this issue by declaring "+" as the separator. Scenes that were saved with "-" remain compatible, as we replace all "-" in the version name with "+" before splitting it.
1 parent 8ffc283 commit 35f209c

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

meshroom/core/__init__.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,8 +262,9 @@ def toComponents(versionName):
262262
return (), ''
263263

264264
status = ''
265-
# If there is a status, it is placed after a "-"
266-
splitComponents = versionName.split("-", maxsplit=1)
265+
# If there is a status, it is placed after a "-" (up to Meshroom 2025.1.0) or a "+"
266+
versionName = versionName.replace("-", "+") # Keep compatibility for scenes created with 2025.1.0 or older
267+
splitComponents = versionName.split("+", maxsplit=1)
267268
# If there is no status, splitComponents is equal to [versionName]
268269
if len(splitComponents) > 1:
269270
status = splitComponents[-1]

0 commit comments

Comments
 (0)