This commit is contained in:
DingZQ
2023-10-21 00:00:42 +08:00
parent a98a44b2a4
commit 9fa761e1cd

View File

@@ -149,6 +149,7 @@ async def fastapi_dump_inp(network: str, inp: str) -> bool:
@app.get("/runproject/", response_class = PlainTextResponse)
async def fastapi_run_project(network: str) -> str:
if not app.state.is_simulation:
app.state.is_simulation = True
result = run_project(network)
app.state.is_simulation = False
return result