Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -324,7 +324,7 @@ async def read_process_output(process, websocket):
|
|
324 |
"type": "terminal-data",
|
325 |
"data": line.strip().decode('utf-8'),
|
326 |
}
|
327 |
-
await websocket.send(event)
|
328 |
|
329 |
|
330 |
async for line in process.stderr:
|
@@ -333,7 +333,7 @@ async def read_process_output(process, websocket):
|
|
333 |
"type": "terminal-error",
|
334 |
"data": line.strip().decode('utf-8'),
|
335 |
}
|
336 |
-
await websocket.send(event)
|
337 |
|
338 |
async def handle_user_input(websocket, process):
|
339 |
while True:
|
|
|
324 |
"type": "terminal-data",
|
325 |
"data": line.strip().decode('utf-8'),
|
326 |
}
|
327 |
+
await websocket.send(json.dumps(event))
|
328 |
|
329 |
|
330 |
async for line in process.stderr:
|
|
|
333 |
"type": "terminal-error",
|
334 |
"data": line.strip().decode('utf-8'),
|
335 |
}
|
336 |
+
await websocket.send(json.dumps(event))
|
337 |
|
338 |
async def handle_user_input(websocket, process):
|
339 |
while True:
|