Epic 6, Story 7, Task 111: Comprehensive install event-contract logging quality
Task ID: E6:S07:T111
Status: COMPLETE
Priority: CRITICAL
Estimated Effort: Large
Created: 2026-04-09
Code: E6S07T111
Implementation note: Released v0.6.7.111+1 (SemVer v0.4.721+1): CLI install JSON event contract, strict option, ai-dev-kit logs validate-install-log, tests/docs. Verification closure recorded in v0.6.7.111+2 (SemVer v0.4.722+2).
Upstream: FR-078 - Comprehensive install event-contract logging quality
Input
- Existing install logging behavior from FR-047 (CLI + framework installer integration).
- Requirement for complete, high-fidelity local install telemetry to improve AI Dev Kit quality and release readiness.
Deliverable
- A strict install telemetry contract and implementation where each emitted event captures
intent,action, andresult, with deterministic run/step correlation and local forensic artifacts for maintainers.
Scope
- Define canonical event schema for install telemetry (required fields + optional extensions).
- Instrument CLI install execution and framework-specific installers to emit full step/sub-step events.
- Capture decision intent and branch rationale (mode/backend/fallback/skip).
- Normalize result payloads (status, duration, exit code, validation outcomes, error classes).
- Generate deterministic local run artifacts suitable for downstream analysis and triage.
- Add tests and validation checks for schema completeness, linkage integrity, and redaction guarantees.
Acceptance Criteria
- AC1: Every install step and sub-step is reconstructable as
intent -> action -> result. - AC2: Correlation fields (
install_run_id,step_id, parent/child linkage) allow deterministic timeline reconstruction. - AC3: Missing mandatory event fields are caught by automated validation/tests.
- AC4: Result payloads include normalized status, timing, exit, and validation details.
- AC5: Local run artifacts contain quality signals sufficient for maintainers to analyze and reproduce install behavior.
- AC6: Redaction tests pass and confirm no secrets are emitted.
Verification evidence (2026-04-10)
python -m pytest tests/cli/test_install_logging.py tests/cli/test_logs_command.py -q→ 11 passedpython -m pytest tests/cli/test_install_logging.py -q -k "strict_event_contract or include_event_contract or redaction"→ 4 passed