Files
John SmithandClaude Opus 4.8 57f8f81e56 feat(phase-4): add OSS migration health check CI gate
Phase 4 of the OSS roadmap: continuous cleanup & verification.
This commit adds scripts/check_oss_migration_health.py — a CI
gate that enforces the migration invariants.

What it checks (6/6 passing):
1. Required OSS deps present in pyproject.toml (instructor,
   taskiq, taskiq-nats, rich, rich-click, questionary,
   fastapi-users, casbin, guardrails-ai, mcp).
2. Dead code removed (4 legacy view files from Phase 1.5).
3. Required docs exist (5 spike markdown files).
4. No oversized spike files (each <= 300 LOC or has OWNER
   annotation).
5. Phase 0 contracts still hold (TRACE_CONTEXT_INTERFACE_VERSION
   = 1.0.0, AGENT_ACTOR_INTERFACE_VERSION = 1.0.0, EchoAgent
   satisfies AgentActorProtocol).
6. Summary line.

Also adds the missing deps to pyproject.toml (casbin,
guardrails-ai, mcp) so the dep check passes.

Usage:
  python3 scripts/check_oss_migration_health.py

Exit 0 on success, 1 on any failure. Intended to be called
from a pre-commit hook or a CI step.

Output:
  [OK] 10 required deps present
  [OK] 4 legacy files removed
  [OK] 5 spike docs present
  [OK] all spike files <= 300 LOC or have OWNER annotation
  [OK] TRACE_CONTEXT_INTERFACE_VERSION = 1.0.0
  [OK] AGENT_ACTOR_INTERFACE_VERSION = 1.0.0
  [OK] EchoAgent satisfies AgentActorProtocol
  [OK] All checks pass; OSS migration health = GREEN

Co-Authored-By: Claude Opus 4.8 <[email protected]>
2026-06-04 00:24:02 -04:00
..