mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-05-01 08:14:22 +08:00
Merge branch 'main' into PP-350_Corrections-on-the-anycolor-profiles
This commit is contained in:
commit
04cd94e5d2
@ -65,10 +65,15 @@ class BackendPlugin(AdditionalSettingDefinitionsAppender, PluginObject):
|
||||
# STDIN needs to be None because we provide no input, but communicate via a local socket instead.
|
||||
# The NUL device sometimes doesn't exist on some computers.
|
||||
Logger.info(f"Starting backend_plugin [{self._plugin_id}] with command: {self._validatePluginCommand()}")
|
||||
popen_kwargs = {"stdin": None}
|
||||
popen_kwargs = {"stdin": None, "stdout": subprocess.PIPE, "stderr": subprocess.PIPE}
|
||||
if Platform.isWindows():
|
||||
popen_kwargs["creationflags"] = subprocess.CREATE_NO_WINDOW
|
||||
self._process = subprocess.Popen(self._validatePluginCommand(), **popen_kwargs)
|
||||
stdout_data, stderr_data = self._process.communicate()
|
||||
if stderr_data:
|
||||
Logger.warning(f"Info on error-stream when starting backend_plugin [{self._plugin_id}] stderr: {str(stderr_data)}")
|
||||
Logger.info(
|
||||
f"Started backend_plugin [{self._plugin_id}] with PID: {self._process.pid}, stdout: {str(stdout_data)}")
|
||||
self._is_running = True
|
||||
return True
|
||||
except PermissionError:
|
||||
|
@ -27,14 +27,7 @@ class AutoDetectBaudJob(Job):
|
||||
write_timeout = 3
|
||||
read_timeout = 3
|
||||
tries = 2
|
||||
|
||||
programmer = Stk500v2()
|
||||
serial = None
|
||||
try:
|
||||
programmer.connect(self._serial_port)
|
||||
serial = programmer.leaveISP()
|
||||
except ispBase.IspError:
|
||||
programmer.close()
|
||||
|
||||
for retry in range(tries):
|
||||
for baud_rate in self._all_baud_rates:
|
||||
|
Loading…
x
Reference in New Issue
Block a user