gcode_shell_command: change to make it compatible with a py3 virtual env
The change is needed that the module can be used in a python 2 and python 3 virtual env. Signed-off-by: Alex Zellner alexander.zellner@googlemail.com
This commit is contained in:
@@ -32,7 +32,7 @@ class ShellCommand:
|
|||||||
data = os.read(self.proc_fd, 4096)
|
data = os.read(self.proc_fd, 4096)
|
||||||
except Exception:
|
except Exception:
|
||||||
pass
|
pass
|
||||||
data = self.partial_output + data
|
data = self.partial_output + data.decode()
|
||||||
if '\n' not in data:
|
if '\n' not in data:
|
||||||
self.partial_output = data
|
self.partial_output = data
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user