Skip to content

docs(plans): no-upstream action plan v2 — 5-phase execution roadmap#73

Merged
chrisgeo merged 1 commit intomainfrom
feat/no-upstream-action-plan-v2
May 1, 2026
Merged

docs(plans): no-upstream action plan v2 — 5-phase execution roadmap#73
chrisgeo merged 1 commit intomainfrom
feat/no-upstream-action-plan-v2

Conversation

@chrisgeo
Copy link
Copy Markdown
Contributor

@chrisgeo chrisgeo commented May 1, 2026

Summary

Concrete 5-phase execution plan for the no-upstream backlog, following the 2026-05-01 feature-parity audit (#71) and coverage matrix reconciliation (#72). User asked: "create a plan to tackle what we can currently, without upstream apple/container changes" + flagged that `--shm-size` landed in apple/container yesterday.

Reviewed and approved by Momus after 4 iteration cycles fixing real defects (stale work claims, wrong file paths, missing executable QA, ArgumentParser-vs-literal grep mismatches, pipefail / grep-c exit-code semantics).

What's in the plan

Phase 0 — Fork bump (1-2 hr)

Merge `apple/container@main` into `full-chaos/container@tier2-fork-patches` to gain `--shm-size` (PR #1488, merged 2026-04-30) and any other recent landings. Phase 0.4 contains an ArgumentParser-aware grep that identifies which Tier 0 silent-failure candidates have actually been fixed upstream — automatically scoping CHAOS-1375 down.

Phase 1 — Quick wins (2-3 hr)

Three small isolated PRs:

  • CHAOS-1366 — `RuntimeError.imageNotFound(reference:)` mapping (Runtime.swift:169 enum + RunCommandRunner.swift:209-220 dispatch)
  • CHAOS-1369 — Delete deprecated `APIStatsErrorResponse` / `APIErrorResponse` route-level extensions (`APIErrorEnvelope` already conforms in APISchemas.swift:550)
  • CHAOS-1363 — Add `ThrottleInterval` to LaunchAgent plist for fast-crash protection

Phase 2 — Tier 0 sweep (6-10 hr)

Execute CHAOS-1370 family (7 sub-issues, CHAOS-1371-1377) using Recipe A (warn-and-skip pattern from CHAOS-1329/1330/1331). Each has explicit per-task QA: command + file + pass criteria. CHAOS-1377 includes a manual upstream-vs-Container-Compose flag-set diff for `container build`.

Phase 3 — Tier 1 wireup (1-2 days)

  • CHAOS-1368 — Replace volume hardlink-dir fallback with `container volume create` + `container run -v :`. Gated on a 30-min smoke test (does upstream resolve named-volume references?). If smoke fails, file new sub-issue under CHAOS-1378.
  • CHAOS-1336 — Wire `deploy.resources.reservations.{cpus,memory}`, conditional on upstream supporting `--memory-reservation` (currently doesn't; pre-check gates the work).

Phase 4 — Coverage + docs reconciliation (1-2 hr)

After Phase 2/3 land, update coverage.html row notes from "silent failure" to "decoded; warn-skipped"; refresh feature-parity.md, upstream-fork-status.md, AGENTS.md §4 totals.

Phase 5 — Final verification + Linear hygiene (1 hr)

Close 12+ tickets with PR links; comment-and-leave on upstream-blocked items; cleanup outdated duplicates (CHAOS-1300/1301/1302).

Already-shipped verification (not redoing this work)

The plan's §2 explicitly tables work that's ALREADY shipped, verified during planning via grep:

Work Status Verification
R1 (drop ComposeRun's private pullImage) SHIPPED `grep -c "private func pullImage"` returns 0
R2 (consolidate env merging) SHIPPED `mergeServiceEnvironment` exists at Helper Functions.swift:73, all 3 callsites use it
CHAOS-1367 (host-platform pull) SHIPPED in code `Compose+Pull.swift:56-61` already uses `defaultRuntimePlatform()` (CHAOS-1344 fix)

Phase 5 closes those Linear tickets with PR/SHA references — no code change.

Out of scope (deferred to next planning cycle)

  • CHAOS-1334 (network IPAM extensions — needs fork patch)
  • CHAOS-1335 (volume `driver_opts` — partially addressed by CHAOS-1368)
  • CHAOS-1378 family (Tier 3 FRs — upstream issue filings)
  • CHAOS-1332 (frontier AI/LLM provider work)
  • CHAOS-1345 (architectural PRD)

Files

  • `docs/plans/no-upstream-action-plan-v2.md` — the 5-phase plan (893 lines)
  • `docs/plans/no-upstream-refactor-and-linear.md` — historical context (the 2026-04-29 plan that drained R1, R2, CHAOS-1333, CHAOS-1338)
  • `docs/plans/socktainer-pivot-summary.md` — historical context (Docker REST pivot to socktainer per CHAOS-1340 epic, referenced by upstream-fork-status.md §2.E)

The two historical docs were untracked working state from prior sessions; committing them so the v2 plan's references resolve.

Review history (Momus)

  • v1: REJECTED — R1/R2 stale (already shipped), file-path errors, missing executable QA
  • v2: REJECTED — APIErrorEnvelope duplicate-conformance bug, AppleContainerizationRuntime wrong file pointer, Phase 2.2-2.7 collapsed without per-task QA
  • v3: REJECTED — `Flags.swift` greps used literal `"--flag"` strings instead of ArgumentParser `customLong`/`.long`/`.shortAndLong` patterns; CHAOS-1377 build-flag diff false-failed
  • v4: REJECTED — `| tail` masks exit codes without pipefail; `grep -c expect 0` exits 1; directory grep on `Server/Routes/`
  • v5: APPROVED — all references verified, QA gates concrete and shell-safe (§3.1 conventions block), smoke tests gate uncertain paths

Refs

Effort estimate

~3-4 dev-days sequential; ~1.5-2 days with parallelism. Reduced from v1's 4-5 days because R1/R2/CHAOS-1367 are already shipped.

Note

This PR is plan-only (no code changes). Execution PRs (per phase, per CHAOS sub-issue) follow as separate small focused PRs. The plan's §10 documents per-phase rollback if anything breaks.

Concrete execution plan for the no-upstream backlog after the 2026-05-01
feature-parity audit (PR #71) and coverage matrix reconciliation (PR #72).
Reviewed and approved by Momus after 4 iteration cycles.

## What changes

* docs/plans/no-upstream-action-plan-v2.md — 5-phase plan covering the
  CHAOS-1370 Tier 0 sweep + adjacent quick wins. Phases:
  - 0: branch + fork bump (catch up to apple/container HEAD; gain
    --shm-size which landed PR #1488 on 2026-04-30)
  - 1: quick wins (CHAOS-1366 imageNotFound mapping, CHAOS-1369
    deprecation cleanup, CHAOS-1363 LaunchAgent ThrottleInterval)
  - 2: Tier 0 sweep (CHAOS-1371-1377, ~22 silent-failure flags
    converted to warn-skip per the CHAOS-1331 pattern)
  - 3: Tier 1 wireup (CHAOS-1368 named volume runtime CRUD,
    CHAOS-1336 deploy.resources.reservations conditional on
    upstream support)
  - 4: coverage + docs reconciliation (post-Phase 2/3 row-note flips)
  - 5: final verification + Linear hygiene (close 12+ tickets)

* docs/plans/no-upstream-refactor-and-linear.md — historical context
  doc from the 2026-04-29 plan that drained the prior queue (R1, R2,
  CHAOS-1333, CHAOS-1338 coverage portion). Now committed as reference
  for v2's "already shipped" verification table.

* docs/plans/socktainer-pivot-summary.md — historical context doc
  documenting the Docker REST surface pivot to socktainer
  (CHAOS-1340 epic), referenced by upstream-fork-status.md §2.E.

## Plan highlights

* **Already-shipped verification:** R1 (drop ComposeRun's private
  pullImage), R2 (consolidate env merging), and CHAOS-1367 (host-
  platform pull) are confirmed shipped via grep — Phase 5 just closes
  the Linear tickets.

* **Critical scope adjustment:** the Phase 0 fork bump catches up to
  upstream main, which automatically promotes --shm-size, --cap-add/
  --cap-drop, and --ulimit from "Tier 0 silent failure" candidates
  to "working" status. Phase 0.4 contains a verification grep that
  filters CHAOS-1375's scope accordingly (don't warn-skip what now
  works upstream).

* **Smoke test gates:** Phase 3.1 includes a 30-min smoke test that
  determines whether `container run -v <name>:<path>` resolves named
  volumes upstream. Plan accommodates either outcome (proceed with
  CHAOS-1368 OR file new sub-issue under CHAOS-1378).

* **Recipe references:** plan invokes 5 documented recipes (Tier 0
  cleanup, fork patch + wireup, decode + bind-mount, coverage flip,
  CLI subcommand) extracted from prior shipped CHAOS work, ensuring
  consistency with established conventions.

## Out of scope (deferred to next planning cycle)

* CHAOS-1334 (network IPAM extensions — needs fork patch)
* CHAOS-1335 (volume driver_opts — partially addressed by 1368)
* CHAOS-1378 family (Tier 3 FRs — upstream issue filings)
* CHAOS-1332 (frontier AI/LLM provider work)

## Review history

* v1: rejected by Momus (R1/R2 stale, file-path errors, missing
  executable QA)
* v2-v3-v4: rejected over 3 cycles for QA-shape issues (greps for
  literal "--flag" strings vs. ArgumentParser declarations,
  pipefail/grep -c exit-code semantics, directory greps)
* v5: APPROVED — all references verified, QA gates concrete and
  shell-safe, smoke tests gate the uncertain paths

Estimated effort: ~3-4 dev-days sequential, ~1.5-2 days with
parallelism (Phase 1/2 sub-tasks are independent).

Refs: CHAOS-1370, CHAOS-1366, CHAOS-1369, CHAOS-1363, CHAOS-1367,
CHAOS-1368, CHAOS-1336, CHAOS-1371-1377
@chrisgeo chrisgeo merged commit e15cf86 into main May 1, 2026
4 checks passed
@chrisgeo chrisgeo deleted the feat/no-upstream-action-plan-v2 branch May 1, 2026 21:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant