fix: hide code runner console window

This commit is contained in:
Liang Jiaqing committed 2026-05-11 09:39:52 +08:00
1 parent 2d848e9a4e
commit ffeae5e59b
1 file changed
+2 -1
+2 -1
View File
@@ -51,7 +51,8 @@ def code_run(code, code_type="python", timeout=60, cwd=None, code_cwd=None, stop
try:
process = subprocess.Popen(
cmd, stdout=subprocess.PIPE, stderr=subprocess.STDOUT,
bufsize=0, cwd=cwd, startupinfo=startupinfo
bufsize=0, cwd=cwd, startupinfo=startupinfo,
creationflags=0x08000000 if os.name == 'nt' else 0
)
start_t = time.time()
t = threading.Thread(target=stream_reader, args=(process, full_stdout), daemon=True)