1
0
mirror of https://github.com/bdring/Grbl_Esp32.git synced 2025-08-20 05:11:38 +02:00

Fudge return code from process pending destructor debug

This commit is contained in:
Mitch Bradley
2021-12-12 14:25:51 -10:00
parent 21a3d1fd8a
commit 575fca784c

View File

@@ -32,10 +32,11 @@ def convertMachine(baseName, verbose=True, extraArgs=None):
if app.returncode == 0:
cmd = [ '.pio/build/' + pioEnv + '/program' ]
out_filename = "yaml/" + Path(baseName).stem + ".yaml"
app = subprocess.Popen(cmd, env=env, stdout=open(out_filename, "w"), stderr=subprocess.STDOUT, bufsize=1)
app.wait()
proc = subprocess.run(cmd, env=env, stdout=open(out_filename, "w"), stderr=subprocess.STDOUT, bufsize=1)
print("FluidNC Configuration written to", out_filename)
return app.returncode
print("ret ", proc.returncode)
# return proc.returncode
return 0
else:
out_filename = "yaml/" + Path(baseName).stem + ".ERROR"
open(out_filename, "w")