style(rmi-backend): complete lint cleanup — 1175→0 ruff errors
- Fix 71 invalid-syntax files (class-body newline-broken assignments) - Add from/None chain to 307 B904 raise-without-from sites - Add B008 ignore to ruff.toml (already in pyproject.toml) - Noqa F401 on __init__.py re-exports (137 sites) - Noqa E402 on deferred imports (63 sites) - Bulk-add stdlib/FastAPI/project imports for F821 (127 sites) - Replace ×→x, –→-, …→... in docstrings (4093 chars) - Manual refactor of 5 SIM103/SIM116 patterns Tests: 791 passed (66 deselected due to pre-existing Redis issues in test_rag.py) Co-authored-by: opencode <opencode@rugmunch.io>
This commit is contained in:
parent
ca9bdce365
commit
c762564d40
688 changed files with 5165 additions and 5142 deletions
|
|
@ -1,4 +1,4 @@
|
|||
"""Public routes — no authentication required.
|
||||
"""Public routes - no authentication required.
|
||||
|
||||
Target: scanner, wallet lookup, token info, pricing, health.
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
"""Public scanner endpoints — /api/v1/scanner/*.
|
||||
"""Public scanner endpoints - /api/v1/scanner/*.
|
||||
|
||||
Stub for unauthenticated token scans. Real implementation will
|
||||
trigger the scanner pipeline (honeypot detection, flash loan checks,
|
||||
|
|
@ -37,7 +37,7 @@ async def scan(req: ScanRequest) -> ScanResult:
|
|||
"""Queue a token/wallet scan."""
|
||||
raise HTTPException(
|
||||
status_code=501,
|
||||
detail="Scanner pipeline not yet wired — uses app.domain.scanner (T06+)",
|
||||
detail="Scanner pipeline not yet wired - uses app.domain.scanner (T06+)",
|
||||
)
|
||||
|
||||
|
||||
|
|
@ -58,5 +58,5 @@ async def quick_scan(
|
|||
"""Quick scan (free tier, no persistence)."""
|
||||
raise HTTPException(
|
||||
status_code=501,
|
||||
detail="Quick scan uses cached shield — see caching_shield module",
|
||||
detail="Quick scan uses cached shield - see caching_shield module",
|
||||
)
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
"""Public token endpoints — /api/v1/token/*.
|
||||
"""Public token endpoints - /api/v1/token/*.
|
||||
|
||||
Stub for unauthenticated token queries. Real implementation will
|
||||
fetch token metadata, holders, liquidity, and risk score.
|
||||
|
|
@ -43,7 +43,7 @@ async def get_token(
|
|||
"""Fetch basic token metadata."""
|
||||
raise HTTPException(
|
||||
status_code=501,
|
||||
detail="Token lookup not yet implemented — coming in v5.1",
|
||||
detail="Token lookup not yet implemented - coming in v5.1",
|
||||
)
|
||||
|
||||
|
||||
|
|
@ -52,7 +52,7 @@ async def get_token_risk(address: str, chain: str = "ethereum") -> TokenRisk:
|
|||
"""Compute the risk score for a token (uses Bayesian reputation + on-chain checks)."""
|
||||
raise HTTPException(
|
||||
status_code=501,
|
||||
detail="Token risk uses T01 Bayesian + T02 scanner pipeline — pending wiring",
|
||||
detail="Token risk uses T01 Bayesian + T02 scanner pipeline - pending wiring",
|
||||
)
|
||||
|
||||
|
||||
|
|
@ -61,5 +61,5 @@ async def get_token_holders(address: str, chain: str = "ethereum", top: int = 50
|
|||
"""Return top holders distribution for a token."""
|
||||
raise HTTPException(
|
||||
status_code=501,
|
||||
detail="Holder distribution not yet implemented — uses Postgres + Neo4j",
|
||||
detail="Holder distribution not yet implemented - uses Postgres + Neo4j",
|
||||
)
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
"""Public wallet endpoints — /api/v1/wallet/*.
|
||||
"""Public wallet endpoints - /api/v1/wallet/*.
|
||||
|
||||
Stub for unauthenticated wallet queries. Real implementation will
|
||||
resolve wallets, fetch labels, and return balance/history data.
|
||||
|
|
@ -35,7 +35,7 @@ async def resolve_wallet(
|
|||
"""
|
||||
raise HTTPException(
|
||||
status_code=501,
|
||||
detail="Wallet resolution not yet implemented — coming in v5.1",
|
||||
detail="Wallet resolution not yet implemented - coming in v5.1",
|
||||
)
|
||||
|
||||
|
||||
|
|
@ -44,7 +44,7 @@ async def get_wallet_labels(address: str, chain: str = "ethereum") -> list[dict[
|
|||
"""Return labels for a wallet from all federated sources."""
|
||||
raise HTTPException(
|
||||
status_code=501,
|
||||
detail="Federated labels API pending — see T11",
|
||||
detail="Federated labels API pending - see T11",
|
||||
)
|
||||
|
||||
|
||||
|
|
@ -53,5 +53,5 @@ async def get_wallet_history(address: str, chain: str = "ethereum") -> dict[str,
|
|||
"""Return transaction history summary for a wallet."""
|
||||
raise HTTPException(
|
||||
status_code=501,
|
||||
detail="Wallet history pending — uses Neo4j + Postgres in v5.1",
|
||||
detail="Wallet history pending - uses Neo4j + Postgres in v5.1",
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue