From 6d87716b1d6b8278754d35449c61edb32e0539b1 Mon Sep 17 00:00:00 2001 From: Richard Mitchell <2081919+richardjm@users.noreply.github.com> Date: Mon, 27 Sep 2021 16:44:11 +0100 Subject: [PATCH] gcode_shell_command: Fix issue with partial lines being repeated (#118) Without clearing the partial line on a full line being sent the self.partial_output was repeated for every subsequent line. --- resources/gcode_shell_command.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/resources/gcode_shell_command.py b/resources/gcode_shell_command.py index 4138172..85c1cb6 100755 --- a/resources/gcode_shell_command.py +++ b/resources/gcode_shell_command.py @@ -40,6 +40,8 @@ class ShellCommand: split = data.rfind('\n') + 1 self.partial_output = data[split:] data = data[:split] + else: + self.partial_output = "" self.gcode.respond_info(data) cmd_RUN_SHELL_COMMAND_help = "Run a linux shell command"