Spaces:
Running
Running
Fix backend status endpoint returning state linfo
Browse files
app.py
CHANGED
|
@@ -51,7 +51,12 @@ async def query_google_scholar(params: APISearchParams):
|
|
| 51 |
|
| 52 |
@app.get('/')
|
| 53 |
async def status():
|
| 54 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 55 |
|
| 56 |
|
| 57 |
@app.post("/search_patents")
|
|
|
|
| 51 |
|
| 52 |
@app.get('/')
|
| 53 |
async def status():
|
| 54 |
+
backend_keys = [k[0] for k in backend_status.items()]
|
| 55 |
+
backend_status_dict = {}
|
| 56 |
+
|
| 57 |
+
for k in backend_keys:
|
| 58 |
+
backend_status_dict[k] = backend_status.get(k)
|
| 59 |
+
return {"status": "running", "backend_status": backend_status_dict}
|
| 60 |
|
| 61 |
|
| 62 |
@app.post("/search_patents")
|