Spaces:
Sleeping
Sleeping
Update main.py
Browse files
main.py
CHANGED
|
@@ -257,6 +257,21 @@ def root():
|
|
| 257 |
"timestamp": datetime.utcnow().isoformat() + "Z",
|
| 258 |
}
|
| 259 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 260 |
@app.get("/health")
|
| 261 |
def health():
|
| 262 |
brain_ok = False
|
|
|
|
| 257 |
"timestamp": datetime.utcnow().isoformat() + "Z",
|
| 258 |
}
|
| 259 |
|
| 260 |
+
@app.get("/version")
|
| 261 |
+
def version_check():
|
| 262 |
+
"""
|
| 263 |
+
DEBUG: Confirma exactamente qué versión de agent_orchestrator.py está
|
| 264 |
+
cargada en memoria en este momento. Si esto no coincide con lo que
|
| 265 |
+
subiste, el problema es el sync — no el código.
|
| 266 |
+
"""
|
| 267 |
+
try:
|
| 268 |
+
from modules.agent_orchestrator import ORCHESTRATOR_VERSION
|
| 269 |
+
return {"orchestrator_version": ORCHESTRATOR_VERSION, "status": "modulo cargado correctamente"}
|
| 270 |
+
except ImportError as e:
|
| 271 |
+
return {"orchestrator_version": "NO DISPONIBLE", "error": str(e)}
|
| 272 |
+
except AttributeError:
|
| 273 |
+
return {"orchestrator_version": "VERSION ANTERIOR — sin marcador", "nota": "el módulo cargado no tiene ORCHESTRATOR_VERSION, es código viejo"}
|
| 274 |
+
|
| 275 |
@app.get("/health")
|
| 276 |
def health():
|
| 277 |
brain_ok = False
|