Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLipu Fei <lipu.fei815@gmail.com>2019-09-24 15:26:43 +0300
committerLipu Fei <lipu.fei815@gmail.com>2019-09-24 15:26:43 +0300
commit94e89ad4ac36e6bdb5784d7a26d78e26da2f42e9 (patch)
tree231ffac63681f867fec3640dee1453a1212c179f /plugins/VersionUpgrade/VersionUpgrade43to44
parenta741530db27b90013eedab8649bb6e22858938b7 (diff)
parentbd314a765f6f8c04bd6b58d26876898b4e7b63e6 (diff)
Fix merge conflicts with master
Diffstat (limited to 'plugins/VersionUpgrade/VersionUpgrade43to44')
-rw-r--r--plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py18
-rw-r--r--plugins/VersionUpgrade/VersionUpgrade43to44/__init__.py1
2 files changed, 14 insertions, 5 deletions
diff --git a/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py b/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py
index 678066c3e8..195bc70016 100644
--- a/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py
+++ b/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py
@@ -12,6 +12,15 @@ _renamed_container_id_map = {
"ultimaker2_extended_0.4": "ultimaker2_extended_olsson_0.4",
"ultimaker2_extended_0.6": "ultimaker2_extended_olsson_0.6",
"ultimaker2_extended_0.8": "ultimaker2_extended_olsson_0.8",
+ # HMS434 "extra coarse", "super coarse", and "ultra coarse" are removed.
+ "hms434_global_Extra_Coarse_Quality": "hms434_global_Normal_Quality",
+ "hms434_global_Super_Coarse_Quality": "hms434_global_Normal_Quality",
+ "hms434_global_Ultra_Coarse_Quality": "hms434_global_Normal_Quality",
+ # HMS434 "0.25", "0.6", "1.2", and "1.5" nozzles are removed.
+ "hms434_0.25tpnozzle": "hms434_0.4tpnozzle",
+ "hms434_0.6tpnozzle": "hms434_0.4tpnozzle",
+ "hms434_1.2tpnozzle": "hms434_0.4tpnozzle",
+ "hms434_1.5tpnozzle": "hms434_0.4tpnozzle",
}
@@ -42,7 +51,7 @@ class VersionUpgrade43to44(VersionUpgrade):
#
# This renames the renamed settings in the containers.
def upgradeInstanceContainer(self, serialized: str, filename: str) -> Tuple[List[str], List[str]]:
- parser = configparser.ConfigParser(interpolation=None)
+ parser = configparser.ConfigParser(interpolation = None)
parser.read_string(serialized)
# Update version number.
@@ -58,12 +67,13 @@ class VersionUpgrade43to44(VersionUpgrade):
## Upgrades stacks to have the new version number.
def upgradeStack(self, serialized: str, filename: str) -> Tuple[List[str], List[str]]:
- parser = configparser.ConfigParser(interpolation=None)
+ parser = configparser.ConfigParser(interpolation = None)
parser.read_string(serialized)
# Update version number.
- if "metadata" in parser:
- parser["metadata"]["setting_version"] = "10"
+ if "metadata" not in parser:
+ parser["metadata"] = {}
+ parser["metadata"]["setting_version"] = "10"
if "containers" in parser:
# With the ContainerTree refactor, UM2 with Olsson block got moved to a separate definition.
diff --git a/plugins/VersionUpgrade/VersionUpgrade43to44/__init__.py b/plugins/VersionUpgrade/VersionUpgrade43to44/__init__.py
index 411a75d385..506ec6c03d 100644
--- a/plugins/VersionUpgrade/VersionUpgrade43to44/__init__.py
+++ b/plugins/VersionUpgrade/VersionUpgrade43to44/__init__.py
@@ -59,4 +59,3 @@ def getMetaData() -> Dict[str, Any]:
def register(app: "Application") -> Dict[str, Any]:
return {"version_upgrade": upgrade}
-