Deploy AIOS web (React glide grid + FastAPI slice)
Browse files- RELEASES.json +1 -1
- VERSION +1 -1
- api/routes_external.py +3 -3
- api/routes_odoo_tables.py +9 -7
- web/public/AIOS_DEPLOY_RECEIPT +1 -1
RELEASES.json
CHANGED
|
@@ -1,4 +1,4 @@
|
|
| 1 |
{
|
| 2 |
-
"current": "
|
| 3 |
"releases": []
|
| 4 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"current": "ef4815677",
|
| 3 |
"releases": []
|
| 4 |
}
|
VERSION
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
|
|
|
|
| 1 |
+
ef4815677
|
api/routes_external.py
CHANGED
|
@@ -5265,11 +5265,11 @@ def _mcp_database_actions(session, rows):
|
|
| 5265 |
def _website_runtime_metadata():
|
| 5266 |
"""Read configured runtime metadata and existing smoke evidence without starting a process."""
|
| 5267 |
import os
|
| 5268 |
-
import sys
|
| 5269 |
import website_tools
|
| 5270 |
|
| 5271 |
-
status = getattr(
|
| 5272 |
-
if
|
|
|
|
| 5273 |
return False
|
| 5274 |
node = Path(os.environ.get("POMERADO_NODE", ""))
|
| 5275 |
package = Path(os.environ.get("POMERADO_PACKAGE_ROOT", ""))
|
|
|
|
| 5265 |
def _website_runtime_metadata():
|
| 5266 |
"""Read configured runtime metadata and existing smoke evidence without starting a process."""
|
| 5267 |
import os
|
|
|
|
| 5268 |
import website_tools
|
| 5269 |
|
| 5270 |
+
status = getattr(deps.running_main(), "WEBSITE_RUNTIME", {})
|
| 5271 |
+
if (not isinstance(status, dict) or status.get("ready") is not True
|
| 5272 |
+
or status.get("state") not in {"prepared", "external"}):
|
| 5273 |
return False
|
| 5274 |
node = Path(os.environ.get("POMERADO_NODE", ""))
|
| 5275 |
package = Path(os.environ.get("POMERADO_PACKAGE_ROOT", ""))
|
api/routes_odoo_tables.py
CHANGED
|
@@ -582,21 +582,21 @@ _SYNC_STAMP_FORMATS = ("%Y-%m-%d %H:%M:%S", "%Y-%m-%d %H:%M:%S.%f", "%Y-%m-%dT%H
|
|
| 582 |
|
| 583 |
|
| 584 |
def _parse_sync_stamp(text):
|
| 585 |
-
"""
|
| 586 |
-
anything at all, and an unparseable stamp must produce an UNKNOWN verdict rather than a
|
| 587 |
-
confident one."""
|
| 588 |
import datetime as _dt
|
| 589 |
raw = str(text or "").strip()
|
| 590 |
if not raw:
|
| 591 |
return None
|
| 592 |
for fmt in _SYNC_STAMP_FORMATS:
|
| 593 |
try:
|
| 594 |
-
return _dt.datetime.strptime(raw, fmt)
|
| 595 |
except ValueError:
|
| 596 |
continue
|
| 597 |
try:
|
| 598 |
-
|
| 599 |
-
|
|
|
|
|
|
|
| 600 |
return None
|
| 601 |
|
| 602 |
|
|
@@ -622,7 +622,9 @@ def stuck_verdict(phase, updated_at, cadence_seconds, now=None):
|
|
| 622 |
if when is None:
|
| 623 |
return None, ("this phase is running and its last progress stamp could not be read, so "
|
| 624 |
"whether it is advancing is unknown")
|
| 625 |
-
now = now or _dt.datetime.
|
|
|
|
|
|
|
| 626 |
limit = max(int(cadence_seconds or 0), 60) * 2
|
| 627 |
if (now - when).total_seconds() > limit:
|
| 628 |
return True, (f"this phase has stayed running with no progress since {when}, which is "
|
|
|
|
| 582 |
|
| 583 |
|
| 584 |
def _parse_sync_stamp(text):
|
| 585 |
+
"""Parse a sync stamp as UTC, treating naive stamps as UTC, or return None."""
|
|
|
|
|
|
|
| 586 |
import datetime as _dt
|
| 587 |
raw = str(text or "").strip()
|
| 588 |
if not raw:
|
| 589 |
return None
|
| 590 |
for fmt in _SYNC_STAMP_FORMATS:
|
| 591 |
try:
|
| 592 |
+
return _dt.datetime.strptime(raw, fmt).replace(tzinfo=_dt.timezone.utc)
|
| 593 |
except ValueError:
|
| 594 |
continue
|
| 595 |
try:
|
| 596 |
+
parsed = _dt.datetime.fromisoformat(raw.replace("Z", "+00:00"))
|
| 597 |
+
return (parsed.replace(tzinfo=_dt.timezone.utc) if parsed.tzinfo is None
|
| 598 |
+
else parsed.astimezone(_dt.timezone.utc))
|
| 599 |
+
except (ValueError, OverflowError):
|
| 600 |
return None
|
| 601 |
|
| 602 |
|
|
|
|
| 622 |
if when is None:
|
| 623 |
return None, ("this phase is running and its last progress stamp could not be read, so "
|
| 624 |
"whether it is advancing is unknown")
|
| 625 |
+
now = now or _dt.datetime.now(_dt.timezone.utc)
|
| 626 |
+
now = (now.replace(tzinfo=_dt.timezone.utc) if now.tzinfo is None
|
| 627 |
+
else now.astimezone(_dt.timezone.utc))
|
| 628 |
limit = max(int(cadence_seconds or 0), 60) * 2
|
| 629 |
if (now - when).total_seconds() > limit:
|
| 630 |
return True, (f"this phase has stayed running with no progress since {when}, which is "
|
web/public/AIOS_DEPLOY_RECEIPT
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
|
|
|
|
| 1 |
+
a314bdd2111bd1adfcca333a4207be3aff8b38bc23fc6fdc371fdda404d33424
|