remove REVIEW.md from repo

This commit is contained in:
2026-09-10 11:50:12 +02:00
parent 4c12e8bb0c
commit b92f8d8914
15 changed files with 397 additions and 639 deletions
+10 -10
View File
@@ -1,6 +1,6 @@
import sqlite3
from pathlib import Path
from typing import Any, Dict, List, Optional
from typing import Any
from app_state import StateStore, load_account
@@ -9,10 +9,10 @@ def health_payload(
data_dir: Path,
session_dir: Path,
state_store: StateStore,
continuous_snapshot: Dict[str, Any],
continuous_snapshot: dict[str, Any],
job_queue_size: int,
account_ids: Optional[List[str]] = None,
) -> Dict[str, Any]:
account_ids: list[str] | None = None,
) -> dict[str, Any]:
"""
Return a health-check payload for the application.
@@ -32,7 +32,7 @@ def health_payload(
# Per-account health
if account_ids:
account_checks: Dict[str, Any] = {}
account_checks: dict[str, Any] = {}
for acc_id in account_ids:
acc_dir = data_dir / "accounts" / acc_id
session_file = session_dir / f"{acc_id}.session"
@@ -55,10 +55,10 @@ def health_payload(
return {"ok": ok, "status": "ok" if ok else "degraded", "checks": checks}
def _dir_check(path: Path, writable: bool = False) -> Dict[str, Any]:
def _dir_check(path: Path, writable: bool = False) -> dict[str, Any]:
path.mkdir(parents=True, exist_ok=True)
ok = path.exists() and path.is_dir()
payload: Dict[str, Any] = {"ok": ok, "path": str(path)}
payload: dict[str, Any] = {"ok": ok, "path": str(path)}
if writable:
probe = path / ".healthcheck"
try:
@@ -70,7 +70,7 @@ def _dir_check(path: Path, writable: bool = False) -> Dict[str, Any]:
return payload
def _state_check(state_store: StateStore) -> Dict[str, Any]:
def _state_check(state_store: StateStore) -> dict[str, Any]:
try:
state = state_store.load()
data_dir = state_store.path.parent
@@ -105,7 +105,7 @@ def _state_check(state_store: StateStore) -> Dict[str, Any]:
return {"ok": False, "path": str(state_store.path), "error": str(exc)}
def _sqlite_check() -> Dict[str, Any]:
def _sqlite_check() -> dict[str, Any]:
try:
conn = sqlite3.connect(":memory:")
conn.execute("SELECT 1")
@@ -115,7 +115,7 @@ def _sqlite_check() -> Dict[str, Any]:
return {"ok": False, "error": str(exc)}
def _continuous_check(snapshot: Dict[str, Any]) -> Dict[str, Any]:
def _continuous_check(snapshot: dict[str, Any]) -> dict[str, Any]:
running_accounts = snapshot.get("running_accounts")
if running_accounts is None:
running_accounts = snapshot