Tasks: Operator Config & Install Ergonomics

Mission: operator-config-ergonomics-01M04YK8 · Branch: fix/operator-config-ergonomics Spec: spec.md · Plan: plan.md (IC→WP table = PPC-6) · Design: design-record.md

Dependency graph: WP01 → {WP02, WP03}, {WP02, WP03} → {WP04, WP05}, {WP01..WP05} → WP06. Parallelism: WP02 ∥ WP03 (after WP01); WP04 ∥ WP05 (after WP02 AND WP03 — WP04/WP05 depend on WP03 for the doctor auto-discovery seam so their _*_doctor.py siblings self-register without editing doctor.py; post-tasks squad fix).

Subtask Index

IDDescriptionWPParallel
T001get_packs_root_default() = get_built_in_pack_root().parent + kernel state-root primitiveWP01
T002kernel/env_expand.py: expand_env_template(inject_defaults), token detector, UnresolvedEnvTokenErrorWP01
T003Default-injection registry: ${SPEC_KITTY_PACKS_ROOT}get_packs_root_default()WP01
T004org_pack_config._expand_path_template delegates (inject_defaults=False); fail-loud preservedWP01
T005Tests C-EXP-1..5 (+ kernel-no-upward-import arch test)WP01
T006bootstrap/env_file.py: KEY=VALUE parser, two-tier discovery, {home,repo} + one setdefaultWP02
T007config.yaml env_file pointer read + single expansion (outside extra="forbid")WP02
T008Fail policy: absent→warn, unreadable→loud, malformed→skip, locator-recursion→ignoreWP02
T009Wire loader as first statements of specify_cli/__init__.py (before line 36)WP02
T010Tests C-LDR-1..7 + import-purity arch testWP02
T011doctrine/provenance.py: 3-class path→token normalizerWP03[P]
T012Route charter catalog source (compiler.py:1424/1447) through normalizer; retire marker-trim for catalog onlyWP03[P]
T013Route manifest source (projection.py:56) through normalizer; leave output_path repo-relativeWP03[P]
T014Heal migration (both carriers; idempotent)WP03[P]
T015_provenance_doctor.py sibling — leak-checkWP03[P]
T016Tests C-PRV-1..6 (re-bake gate, invariance, heal idempotent, 3-class matrix, excluded-callers byte-unchanged)WP03[P]
T017Provision migration: seed (never PACKS_ROOT), register pointer, gitignore+claudeignore; distinct target_version vs #3381WP04[P]
T018Secret redaction fail-closed allowlist + integration into doctor/status/logsWP04[P]
T019_env_file_doctor.py sibling — env-file health (names only)WP04[P]
T020Tests C-MIG-1/2 (idempotent, no-PACKS_ROOT-seed + TEMPLATE_ROOT gate), C-SEC-1/2WP04[P]
T021Channel preference accessor (SPEC_KITTY_PRERELEASE, default off, single-read)WP05[P]
T022Channel-aware "latest" (provider/simple_index/upgrade_probe) — stable-only defaultWP05[P]
T023Pinned rc install command (==<rc>) + planner cache-key includes channelWP05[P]
T024_channel_doctor.py sibling — channel lineWP05[P]
T025Tests C-CHN-1..3WP05[P]
T026ADR: env-resolution seam + provenance form + layeringWP06
T027ADR: default-off rc channelWP06
T028Team Kitty (SaaS) architecture section + interaction diagramWP06
T029Consumption docs (env-vars, configuration, install/upgrade, sync-drain/consent/readiness) + SOURCE spk-team-* skillsWP06
T030CHANGELOG.md entryWP06

Work Packages

WP01 — Kernel env-expansion seam (IC-01) · prompt: tasks/WP01-kernel-env-expansion-seam.md

Goal: one kernel ${VAR} expander (two policies) + get_packs_root_default + state-root primitive; org_pack_config delegates. Priority: P1 (foundation). Independent test: C-EXP-1..5. Deps: none. Subtasks T001–T005 (~5). ~260 lines.

WP02 — Pre-import .kitty.env loader + config pointer (IC-02) · prompt: tasks/WP02-kitty-env-loader.md

Goal: two-tier .kitty.env seeded pre-import (merge→setdefault); single config.yaml pointer; fail policy. Priority: P1. Independent test: C-LDR-1..7. Deps: WP01. Subtasks T006–T010 (~5). ~300 lines.

WP03 — Portable provenance emit + heal + leak-check (IC-03) · prompt: tasks/WP03-portable-provenance.md

Goal: 3-class shared normalizer; token emit for both carriers; heal migration; provenance doctor. Priority: P1 (US1). Independent test: C-PRV-1..6. Deps: WP01. Subtasks T011–T016 (~6). ~320 lines.

WP04 — Provision migration + secret redaction + config-health doctor (IC-04) · prompt: tasks/WP04-provision-and-secrets.md

Goal: provision migration (never seeds PACKS_ROOT), fail-closed secret allowlist, env-file health doctor. Priority: P1 (US2/US4). Independent test: C-MIG/C-SEC. Deps: WP02. Subtasks T017–T020 (~4). ~250 lines.

WP05 — rc release channel consumer slice (IC-05) · prompt: tasks/WP05-rc-channel.md

Goal: default-off channel; pre-release-aware latest; pinned rc install; channel doctor. Priority: P2 (US3). Independent test: C-CHN-1..3. Deps: WP02. Subtasks T021–T025 (~5). ~270 lines.

WP06 — Docs, ADRs, Team Kitty (SaaS) architecture (IC-06) · prompt: tasks/WP06-docs-adr-saas.md

Goal: 2 ADRs; Team Kitty (SaaS) section + interaction diagram; consumption docs + SOURCE skills; CHANGELOG. Priority: P3 (US5). Independent test: SC-006. Deps: WP01–WP05. Subtasks T026–T030 (~5). ~240 lines.

MVP

WP01 + WP02 + WP03 = the portable-provenance + config-seam core (US1 ships; US2 opt-in enabled). WP04/WP05/WP06 complete the operator experience.