diff --git a/Jenkinsfile b/Jenkinsfile index f9a3a9864a..a345ebbd05 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -38,20 +38,9 @@ parallel_nodes(['linux && cura', 'windows && cura']) { if (isUnix()) { - // For Linux to show everything - def branch = env.BRANCH_NAME - if(!fileExists("${env.CURA_ENVIRONMENT_PATH}/${branch}")) - { - branch = "master" - } - def uranium_dir = get_workspace_dir("Ultimaker/Uranium/${branch}") - + // For Linux try { - sh """ - cd .. - export PYTHONPATH=.:"${uranium_dir}" - ${env.CURA_ENVIRONMENT_PATH}/${branch}/bin/pytest -x --verbose --full-trace --capture=no ./tests - """ + sh 'make CTEST_OUTPUT_ON_FAILURE=TRUE test' } catch(e) { currentBuild.result = "UNSTABLE" @@ -70,34 +59,6 @@ parallel_nodes(['linux && cura', 'windows && cura']) } } } - - stage('Code Style') - { - if (isUnix()) - { - // For Linux to show everything. - // CMake also runs this test, but if it fails then the test just shows "failed" without details of what exactly failed. - def branch = env.BRANCH_NAME - if(!fileExists("${env.CURA_ENVIRONMENT_PATH}/${branch}")) - { - branch = "master" - } - def uranium_dir = get_workspace_dir("Ultimaker/Uranium/${branch}") - - try - { - sh """ - cd .. - export PYTHONPATH=.:"${uranium_dir}" - ${env.CURA_ENVIRONMENT_PATH}/${branch}/bin/python3 run_mypy.py - """ - } - catch(e) - { - currentBuild.result = "UNSTABLE" - } - } - } } } diff --git a/cmake/CuraTests.cmake b/cmake/CuraTests.cmake index f2ee92d65b..b6d04de036 100644 --- a/cmake/CuraTests.cmake +++ b/cmake/CuraTests.cmake @@ -6,6 +6,8 @@ include(CMakeParseArguments) find_package(PythonInterp 3.5.0 REQUIRED) +add_custom_target(test-verbose COMMAND ${CMAKE_CTEST_COMMAND} --verbose) + function(cura_add_test) set(_single_args NAME DIRECTORY PYTHONPATH) cmake_parse_arguments("" "" "${_single_args}" "" ${ARGN}) diff --git a/cura/BuildVolume.py b/cura/BuildVolume.py index 547c3dae71..1589f16afc 100755 --- a/cura/BuildVolume.py +++ b/cura/BuildVolume.py @@ -489,7 +489,9 @@ class BuildVolume(SceneNode): def _updateRaftThickness(self): old_raft_thickness = self._raft_thickness - self._adhesion_type = self._global_container_stack.getProperty("adhesion_type", "value") + if self._global_container_stack.extruders: + # This might be called before the extruder stacks have initialised, in which case getting the adhesion_type fails + self._adhesion_type = self._global_container_stack.getProperty("adhesion_type", "value") self._raft_thickness = 0.0 if self._adhesion_type == "raft": self._raft_thickness = ( diff --git a/cura/Scene/ConvexHullDecorator.py b/cura/Scene/ConvexHullDecorator.py index 39124c5ba3..0c03ae615b 100644 --- a/cura/Scene/ConvexHullDecorator.py +++ b/cura/Scene/ConvexHullDecorator.py @@ -272,7 +272,7 @@ class ConvexHullDecorator(SceneNodeDecorator): head_and_fans = self._getHeadAndFans().intersectionConvexHulls(mirrored) # Min head hull is used for the push free - convex_hull = self._compute2DConvexHeadFull() + convex_hull = self._compute2DConvexHull() if convex_hull: return convex_hull.getMinkowskiHull(head_and_fans) return None diff --git a/cura/Settings/CuraFormulaFunctions.py b/cura/Settings/CuraFormulaFunctions.py index 1db01857f8..9ef80bd3d4 100644 --- a/cura/Settings/CuraFormulaFunctions.py +++ b/cura/Settings/CuraFormulaFunctions.py @@ -5,6 +5,7 @@ from typing import Any, List, Optional, TYPE_CHECKING from UM.Settings.PropertyEvaluationContext import PropertyEvaluationContext from UM.Settings.SettingFunction import SettingFunction +from UM.Logger import Logger if TYPE_CHECKING: from cura.CuraApplication import CuraApplication @@ -38,7 +39,11 @@ class CuraFormulaFunctions: extruder_position = int(machine_manager.defaultExtruderPosition) global_stack = machine_manager.activeMachine - extruder_stack = global_stack.extruders[str(extruder_position)] + try: + extruder_stack = global_stack.extruders[str(extruder_position)] + except KeyError: + Logger.log("w", "Value for %s of extruder %s was requested, but that extruder is not available" % (property_key, extruder_position)) + return None value = extruder_stack.getRawProperty(property_key, "value", context = context) if isinstance(value, SettingFunction): diff --git a/plugins/Toolbox/resources/qml/ToolboxCompatibilityChart.qml b/plugins/Toolbox/resources/qml/ToolboxCompatibilityChart.qml index a48cb2ee3f..62e1e3ab86 100644 --- a/plugins/Toolbox/resources/qml/ToolboxCompatibilityChart.qml +++ b/plugins/Toolbox/resources/qml/ToolboxCompatibilityChart.qml @@ -83,7 +83,7 @@ Item model: packageData.supported_configs headerDelegate: Rectangle { - color: UM.Theme.getColor("sidebar") + color: UM.Theme.getColor("main_background") height: UM.Theme.getSize("toolbox_chart_row").height Label { diff --git a/plugins/UM3NetworkPrinting/resources/qml/ClusterControlItem.qml b/plugins/UM3NetworkPrinting/resources/qml/ClusterControlItem.qml index 068c369a3f..94e75a6de0 100644 --- a/plugins/UM3NetworkPrinting/resources/qml/ClusterControlItem.qml +++ b/plugins/UM3NetworkPrinting/resources/qml/ClusterControlItem.qml @@ -13,7 +13,7 @@ Component { property var shadowRadius: UM.Theme.getSize("monitor_shadow_radius").width; property var cornerRadius: UM.Theme.getSize("monitor_corner_radius").width; anchors.fill: parent; - color: UM.Theme.getColor("sidebar"); + color: UM.Theme.getColor("main_background"); visible: OutputDevice != null; UM.I18nCatalog { diff --git a/resources/definitions/fdmextruder.def.json b/resources/definitions/fdmextruder.def.json index 19c9e92d18..cb49b1e128 100644 --- a/resources/definitions/fdmextruder.def.json +++ b/resources/definitions/fdmextruder.def.json @@ -78,7 +78,7 @@ "machine_extruder_start_code": { "label": "Extruder Start G-Code", - "description": "Start g-code to execute whenever turning the extruder on.", + "description": "Start g-code to execute when switching to this extruder.", "type": "str", "default_value": "", "settable_per_mesh": false, @@ -124,7 +124,7 @@ "machine_extruder_end_code": { "label": "Extruder End G-Code", - "description": "End g-code to execute whenever turning the extruder off.", + "description": "End g-code to execute when switching away from this extruder.", "type": "str", "default_value": "", "settable_per_mesh": false, diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index 325e4b6c79..c015ab8ccb 100644 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -2406,7 +2406,7 @@ "switch_extruder_retraction_amount": { "label": "Nozzle Switch Retraction Distance", - "description": "The amount of retraction: Set at 0 for no retraction at all. This should generally be the same as the length of the heat zone.", + "description": "The amount of retraction when switching extruders. Set to 0 for no retraction at all. This should generally be the same as the length of the heat zone.", "type": "float", "unit": "mm", "enabled": "retraction_enable", @@ -4456,7 +4456,6 @@ "description": "Amount of offset applied to the roofs of the support.", "unit": "mm", "type": "float", - "minimum_value": "0", "default_value": 0.0, "value": "extruderValue(support_roof_extruder_nr, 'support_interface_offset')", "maximum_value": "extruderValue(support_extruder_nr, 'support_offset')", @@ -4471,7 +4470,6 @@ "description": "Amount of offset applied to the floors of the support.", "unit": "mm", "type": "float", - "minimum_value": "0", "default_value": 0.0, "value": "extruderValue(support_bottom_extruder_nr, 'support_interface_offset')", "maximum_value": "extruderValue(support_extruder_nr, 'support_offset')",