From 4b5eff5ec64abbc4283cfcd119a9f2feb6cda7ac Mon Sep 17 00:00:00 2001 From: Shawn Bruce Date: Thu, 26 Oct 2017 12:42:55 -0400 Subject: [PATCH] Don't set target temp for tools that do not exist. --- src/octoprint/util/comm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/octoprint/util/comm.py b/src/octoprint/util/comm.py index 9799127a..11551adb 100644 --- a/src/octoprint/util/comm.py +++ b/src/octoprint/util/comm.py @@ -2604,7 +2604,7 @@ class MachineCom(object): if not match and support_r: match = regexes_parameters["floatR"].search(cmd) - if match: + if match and self.last_temperature.tools.get(toolNum) is not None: try: target = float(match.group("value")) self.last_temperature.set_tool(toolNum, target=target)