diff options
author | Jaime van Kessel <nallath@gmail.com> | 2019-09-13 10:29:49 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-13 10:29:49 +0300 |
commit | febe953226e65717bee60103755fee6d2bfbe73c (patch) | |
tree | a7c1864d19ba7124b18174377ec157053769418d /plugins/VersionUpgrade/VersionUpgrade43to44 | |
parent | 06103b98d541d8278223b70fd2ac3716cd84e9d3 (diff) |
Don't assert if there are already 7 containers in stack
CURA-6599
Co-Authored-By: Ghostkeeper <Ghostkeeper@users.noreply.github.com>
Diffstat (limited to 'plugins/VersionUpgrade/VersionUpgrade43to44')
-rw-r--r-- | plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py b/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py index a96b38902d..43fae0b472 100644 --- a/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py +++ b/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py @@ -54,7 +54,8 @@ class VersionUpgrade43to44(VersionUpgrade): parser["metadata"]["setting_version"] = "10" # We should only have 6 levels when we start. - assert "7" not in parser["containers"] + if "7" in parser["containers"]: + return ([], []) # We added the intent container in Cura 4.4. This means that all other containers move one step down. parser["containers"]["7"] = parser["containers"]["6"] @@ -66,4 +67,4 @@ class VersionUpgrade43to44(VersionUpgrade): result = io.StringIO() parser.write(result) - return [filename], [result.getvalue()]
\ No newline at end of file + return [filename], [result.getvalue()] |