ndomo 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (247) hide show
  1. package/.bun-version +1 -0
  2. package/.dockerignore +79 -0
  3. package/.editorconfig +18 -0
  4. package/.env.example +19 -0
  5. package/.github/CODEOWNERS +8 -0
  6. package/.github/ISSUE_TEMPLATE/bug_report.yml +62 -0
  7. package/.github/ISSUE_TEMPLATE/config.yml +2 -0
  8. package/.github/ISSUE_TEMPLATE/feature_request.yml +34 -0
  9. package/.github/dependabot.yml +36 -0
  10. package/.github/pull_request_template.md +24 -0
  11. package/.github/release.yml +30 -0
  12. package/.github/workflows/gitleaks.yml +28 -0
  13. package/.github/workflows/release-please.yml +27 -0
  14. package/.github/workflows/smoke.yml +29 -0
  15. package/.husky/commit-msg +1 -0
  16. package/CHANGELOG.md +114 -0
  17. package/Dockerfile +32 -0
  18. package/README.es.md +174 -0
  19. package/README.md +187 -0
  20. package/agents/chronicler.md +98 -0
  21. package/agents/ci-smith.md +136 -0
  22. package/agents/craftsman.md +341 -0
  23. package/agents/deploy-smith.md +138 -0
  24. package/agents/foreman.md +377 -0
  25. package/agents/go-smith.md +164 -0
  26. package/agents/guild.md +188 -0
  27. package/agents/inspector.md +83 -0
  28. package/agents/js-smith.md +127 -0
  29. package/agents/ops-scout.md +173 -0
  30. package/agents/painter.md +200 -0
  31. package/agents/python-smith.md +120 -0
  32. package/agents/ranger.md +307 -0
  33. package/agents/release-smith.md +165 -0
  34. package/agents/rust-smith.md +159 -0
  35. package/agents/sage.md +178 -0
  36. package/agents/scout.md +144 -0
  37. package/agents/scribe.md +156 -0
  38. package/agents/smith.md +201 -0
  39. package/agents/vue-smith.md +155 -0
  40. package/agents/warden.md +216 -0
  41. package/agents/zig-smith.md +156 -0
  42. package/bin/ndomo-analyses.ts +4 -0
  43. package/bin/ndomo-status.ts +4 -0
  44. package/biome.json +57 -0
  45. package/bun.lock +514 -0
  46. package/commitlint.config.js +3 -0
  47. package/config/ndomo.config.json +258 -0
  48. package/config/ndomo.schema.json +166 -0
  49. package/docs/agents.md +375 -0
  50. package/docs/bugs/plan-create-orphan-fk.md +131 -0
  51. package/docs/bugs/task_create_batch-order-index-collision.md +158 -0
  52. package/docs/configuration.md +276 -0
  53. package/docs/database.md +364 -0
  54. package/docs/features/feature-flexible-builder-v1.md +724 -0
  55. package/docs/features/feature-flexible-builder-v2.md +882 -0
  56. package/docs/features/feature-flexible-builder.md +974 -0
  57. package/docs/http-server.md +244 -0
  58. package/docs/installation.md +259 -0
  59. package/docs/integrations.md +129 -0
  60. package/docs/operations/anti-pattern-sub-agent-verify-2026-06-21.md +32 -0
  61. package/docs/operations/audit-v1.md +417 -0
  62. package/docs/operations/audit-v2.md +197 -0
  63. package/docs/operations/audit-v3.md +306 -0
  64. package/docs/operations/db-optimize-foundations.md +123 -0
  65. package/docs/operations/verify-gate-architecture.md +82 -0
  66. package/docs/workflows.md +448 -0
  67. package/opencode.json +5 -0
  68. package/package.json +65 -0
  69. package/release-please-config.json +11 -0
  70. package/scripts/dev-bust-cache.sh +164 -0
  71. package/scripts/install.sh +688 -0
  72. package/scripts/smoke-e2e.ts +704 -0
  73. package/scripts/smoke-hot.ts +417 -0
  74. package/scripts/smoke-http.sh +228 -0
  75. package/scripts/smoke-v4.ts +256 -0
  76. package/scripts/smoke-v5.ts +397 -0
  77. package/scripts/smoke.sh +9 -0
  78. package/scripts/uninstall.sh +224 -0
  79. package/skills/api-security-best-practices/SKILL.md +915 -0
  80. package/skills/bash-scripting/SKILL.md +201 -0
  81. package/skills/bun/SKILL.md +313 -0
  82. package/skills/cavecrew/SKILL.md +82 -0
  83. package/skills/caveman/SKILL.md +74 -0
  84. package/skills/caveman-review/README.md +33 -0
  85. package/skills/caveman-review/SKILL.md +55 -0
  86. package/skills/find-skills/SKILL.md +142 -0
  87. package/skills/frontend-design/LICENSE.txt +177 -0
  88. package/skills/frontend-design/SKILL.md +55 -0
  89. package/skills/golang-patterns/SKILL.md +674 -0
  90. package/skills/golang-security/SKILL.md +185 -0
  91. package/skills/golang-security/evals/evals.json +595 -0
  92. package/skills/golang-security/references/architecture.md +268 -0
  93. package/skills/golang-security/references/checklist.md +80 -0
  94. package/skills/golang-security/references/cookies.md +200 -0
  95. package/skills/golang-security/references/cryptography.md +424 -0
  96. package/skills/golang-security/references/filesystem.md +285 -0
  97. package/skills/golang-security/references/injection.md +315 -0
  98. package/skills/golang-security/references/logging.md +163 -0
  99. package/skills/golang-security/references/memory-safety.md +241 -0
  100. package/skills/golang-security/references/network.md +253 -0
  101. package/skills/golang-security/references/secrets.md +189 -0
  102. package/skills/golang-security/references/third-party.md +159 -0
  103. package/skills/golang-security/references/threat-modeling.md +189 -0
  104. package/skills/golang-testing/SKILL.md +720 -0
  105. package/skills/grill-me/SKILL.md +7 -0
  106. package/skills/javascript-testing-patterns/SKILL.md +537 -0
  107. package/skills/javascript-testing-patterns/references/advanced-testing-patterns.md +513 -0
  108. package/skills/modern-javascript-patterns/SKILL.md +43 -0
  109. package/skills/modern-javascript-patterns/references/advanced-patterns.md +487 -0
  110. package/skills/modern-javascript-patterns/references/details.md +457 -0
  111. package/skills/python-anti-patterns/SKILL.md +349 -0
  112. package/skills/python-design-patterns/SKILL.md +85 -0
  113. package/skills/python-design-patterns/references/details.md +353 -0
  114. package/skills/python-error-handling/SKILL.md +193 -0
  115. package/skills/python-error-handling/references/details.md +171 -0
  116. package/skills/python-testing-patterns/SKILL.md +278 -0
  117. package/skills/python-testing-patterns/references/advanced-patterns.md +411 -0
  118. package/skills/python-testing-patterns/references/details.md +349 -0
  119. package/skills/rust-patterns/SKILL.md +500 -0
  120. package/skills/rust-testing/SKILL.md +501 -0
  121. package/skills/security-review/SKILL.md +504 -0
  122. package/skills/security-review/cloud-infrastructure-security.md +361 -0
  123. package/skills/vue-best-practices/SKILL.md +154 -0
  124. package/skills/vue-best-practices/references/animation-class-based-technique.md +254 -0
  125. package/skills/vue-best-practices/references/animation-state-driven-technique.md +291 -0
  126. package/skills/vue-best-practices/references/component-async.md +97 -0
  127. package/skills/vue-best-practices/references/component-data-flow.md +307 -0
  128. package/skills/vue-best-practices/references/component-fallthrough-attrs.md +174 -0
  129. package/skills/vue-best-practices/references/component-keep-alive.md +137 -0
  130. package/skills/vue-best-practices/references/component-slots.md +216 -0
  131. package/skills/vue-best-practices/references/component-suspense.md +228 -0
  132. package/skills/vue-best-practices/references/component-teleport.md +108 -0
  133. package/skills/vue-best-practices/references/component-transition-group.md +128 -0
  134. package/skills/vue-best-practices/references/component-transition.md +125 -0
  135. package/skills/vue-best-practices/references/composables.md +290 -0
  136. package/skills/vue-best-practices/references/directives.md +162 -0
  137. package/skills/vue-best-practices/references/perf-avoid-component-abstraction-in-lists.md +159 -0
  138. package/skills/vue-best-practices/references/perf-v-once-v-memo-directives.md +182 -0
  139. package/skills/vue-best-practices/references/perf-virtualize-large-lists.md +187 -0
  140. package/skills/vue-best-practices/references/plugins.md +166 -0
  141. package/skills/vue-best-practices/references/reactivity.md +344 -0
  142. package/skills/vue-best-practices/references/render-functions.md +201 -0
  143. package/skills/vue-best-practices/references/sfc.md +310 -0
  144. package/skills/vue-best-practices/references/state-management.md +135 -0
  145. package/skills/vue-best-practices/references/updated-hook-performance.md +187 -0
  146. package/skills/vue-pinia-best-practices/SKILL.md +21 -0
  147. package/skills/vue-pinia-best-practices/reference/pinia-no-active-pinia-error.md +248 -0
  148. package/skills/vue-pinia-best-practices/reference/pinia-setup-store-return-all-state.md +227 -0
  149. package/skills/vue-pinia-best-practices/reference/pinia-store-destructuring-breaks-reactivity.md +193 -0
  150. package/skills/vue-pinia-best-practices/reference/state-url-for-ephemeral-filters.md +238 -0
  151. package/skills/vue-pinia-best-practices/reference/state-use-pinia-for-large-apps.md +262 -0
  152. package/skills/vue-pinia-best-practices/reference/store-method-binding-parentheses.md +191 -0
  153. package/skills/zig-0.16/SKILL.md +840 -0
  154. package/skills/zig-0.16/scripts/check-zig-version.sh +21 -0
  155. package/src/cli/analyses.ts +280 -0
  156. package/src/cli/index.ts +108 -0
  157. package/src/cli/serve.ts +192 -0
  158. package/src/cli/smoke.ts +131 -0
  159. package/src/cli/status.test.ts +204 -0
  160. package/src/cli/status.ts +263 -0
  161. package/src/cli/vacuum.test.ts +82 -0
  162. package/src/cli/vacuum.ts +96 -0
  163. package/src/config/schema.test.ts +88 -0
  164. package/src/config/schema.ts +64 -0
  165. package/src/db/analyses-migration.test.ts +210 -0
  166. package/src/db/analyses.test.ts +466 -0
  167. package/src/db/analyses.ts +375 -0
  168. package/src/db/auto-checkpoint.ts +131 -0
  169. package/src/db/client.test.ts +129 -0
  170. package/src/db/client.ts +55 -0
  171. package/src/db/fts-escape.ts +20 -0
  172. package/src/db/incidents.test.ts +201 -0
  173. package/src/db/incidents.ts +93 -0
  174. package/src/db/index.ts +86 -0
  175. package/src/db/migrations-v13.test.ts +141 -0
  176. package/src/db/migrations-v8.test.ts +301 -0
  177. package/src/db/migrations.ts +147 -0
  178. package/src/db/plan-archive.test.ts +180 -0
  179. package/src/db/plan-archive.ts +274 -0
  180. package/src/db/plan-create.test.ts +276 -0
  181. package/src/db/plan-create.ts +78 -0
  182. package/src/db/plan-files.test.ts +289 -0
  183. package/src/db/plan-update-status.ts +287 -0
  184. package/src/db/plans.test.ts +490 -0
  185. package/src/db/plans.ts +534 -0
  186. package/src/db/resolve-project-dir.test.ts +143 -0
  187. package/src/db/resolve-project-dir.ts +75 -0
  188. package/src/db/rollbacks.test.ts +150 -0
  189. package/src/db/rollbacks.ts +67 -0
  190. package/src/db/schema.ts +907 -0
  191. package/src/db/sessions.test.ts +80 -0
  192. package/src/db/sessions.ts +135 -0
  193. package/src/db/shutdown.test.ts +147 -0
  194. package/src/db/shutdown.ts +45 -0
  195. package/src/db/tasks.test.ts +921 -0
  196. package/src/db/tasks.ts +747 -0
  197. package/src/db/types.ts +619 -0
  198. package/src/http/__tests__/auth.test.ts +196 -0
  199. package/src/http/__tests__/routes.test.ts +465 -0
  200. package/src/http/__tests__/sse.test.ts +317 -0
  201. package/src/http/auth.ts +72 -0
  202. package/src/http/middleware/cors.ts +53 -0
  203. package/src/http/middleware/security-headers.ts +21 -0
  204. package/src/http/routes/events.ts +112 -0
  205. package/src/http/routes/health.ts +51 -0
  206. package/src/http/routes/plans.ts +66 -0
  207. package/src/http/routes/sessions.ts +50 -0
  208. package/src/http/routes/tasks.ts +60 -0
  209. package/src/http/server.ts +95 -0
  210. package/src/http/sse.ts +116 -0
  211. package/src/index.ts +37 -0
  212. package/src/lib.ts +65 -0
  213. package/src/mem/scoped.ts +65 -0
  214. package/src/orchestrator/background.test.ts +268 -0
  215. package/src/orchestrator/background.ts +293 -0
  216. package/src/orchestrator/memory-hook.ts +182 -0
  217. package/src/orchestrator/reconciler.ts +123 -0
  218. package/src/orchestrator/scheduler.test.ts +300 -0
  219. package/src/orchestrator/scheduler.ts +243 -0
  220. package/src/plugin.test.ts +2574 -0
  221. package/src/plugin.ts +1690 -0
  222. package/src/sdk/client.ts +66 -0
  223. package/src/worktrees/manager.ts +236 -0
  224. package/src/worktrees/state.ts +87 -0
  225. package/tests/integration/ranger-flow.test.ts +257 -0
  226. package/tools/analysis_archive.ts +28 -0
  227. package/tools/analysis_create.ts +55 -0
  228. package/tools/analysis_get.ts +33 -0
  229. package/tools/analysis_link_plan.ts +44 -0
  230. package/tools/analysis_list.ts +48 -0
  231. package/tools/analysis_search.ts +36 -0
  232. package/tools/analysis_update.ts +44 -0
  233. package/tools/plan_approve.ts +31 -0
  234. package/tools/plan_create.ts +58 -0
  235. package/tools/plan_get.ts +40 -0
  236. package/tools/plan_list.ts +37 -0
  237. package/tools/plan_search.ts +34 -0
  238. package/tools/plan_update_status.ts +71 -0
  239. package/tools/session_checkpoint.ts +31 -0
  240. package/tools/session_end.ts +26 -0
  241. package/tools/session_start.ts +43 -0
  242. package/tools/task_create_batch.ts +70 -0
  243. package/tools/task_list.ts +35 -0
  244. package/tools/task_next_for_agent.ts +30 -0
  245. package/tools/task_search.ts +34 -0
  246. package/tools/task_update_status.ts +37 -0
  247. package/tsconfig.json +31 -0
@@ -0,0 +1,417 @@
1
+ # ndomo Audit v1 — Operational Gap Analysis
2
+
3
+ **Date:** 2026-06-20
4
+ **Scope:** ndomo project (self-audit)
5
+ **Author:** ops-scout
6
+ **Method:** Read-only recon of repo state (no edits, no commits, no state changes)
7
+
8
+ ---
9
+
10
+ ## Executive Summary
11
+
12
+ ndomo is a young but unusually disciplined OpenCode plugin: strict TS (`tsconfig.json:9-22`), biome-formatted, bundled install path via `scripts/install.sh`, a single trivium-style CI workflow, conventional commits, and 3 ops-specific primary/subagents (`warden`, `ci-smith`, `deploy-smith`, `release-smith`, `ops-scout`) that already encode the discipline the repo lacks in automation. The plugin runtime itself ships a `status` health tool (`src/plugin.ts:665-680`) and uses `console.*` only with an `[ndomo]` prefix.
13
+
14
+ Operational maturity, however, is at "week 1": only one workflow exists (`.github/workflows/smoke.yml`, 20 lines), zero deploy surface beyond shell scripts, no release artifacts (no tags, no `CHANGELOG.md`, no `.github/release.yml`), no secret scanning, no Dependabot/Renovate, no CodeQL, no `Dockerfile`, no `compose.yml`, no `.dockerignore`, no `.npmignore`, no `CODEOWNERS`, no PR template, no `CONTRIBUTING.md`, no branch-protection audit possible (no `gh` auth in this environment), and `package.json:53-55` ships an empty `"repository.url": ""` placeholder. Several dependencies are outdated by major versions (`@biomejs/biome 1.9.4 → 2.5.0`, `typescript 5.9.3 → 6.0.3`).
15
+
16
+ **Top 3 critical gaps:**
17
+
18
+ 1. **[MISSING-001] Zero release process** — no `CHANGELOG.md`, no semver automation, no tags, no GitHub release template, so the v0.1.0 declared in `package.json:3` is fiction from a release-engineering standpoint.
19
+ 2. **[MISSING-007] No secret scanning + GitHub Actions pinned by tag not SHA** — `smoke.yml:13-14` uses `actions/checkout@v4` and `oven-sh/setup-bun@v2`; supply-chain risk combined with no `gitleaks`/`CodeQL` means a compromised action runs unverified.
20
+ 3. **[MISSING-010] No Dependabot/Renovate + outdated major deps** — `npm outdated` shows 2 major-version drifts unreviewed; without automated PRs, drift will accumulate.
21
+
22
+ **Estimated remediation effort:** 8–12 person-days for the Critical + High buckets; achievable in 1 sprint by `ci-smith` + `release-smith` working against a warden-owned `ops-bootstrap-release-ci` plan.
23
+
24
+ ---
25
+
26
+ ## Findings by Dimension
27
+
28
+ ### 1. CI/CD Coverage
29
+
30
+ **Current state:**
31
+ - **1 workflow only:** `.github/workflows/smoke.yml` (20 lines).
32
+ - Triggers: push and PR to `main` (`.github/workflows/smoke.yml:3-7`).
33
+ - Runner: `ubuntu-latest`, single OS, no matrix (`.github/workflows/smoke.yml:11`).
34
+ - Steps: checkout → `oven-sh/setup-bun@v2` (latest, no version pin) → `bun install` → `bun run typecheck` → `bun test` → `bun run test:smoke` (`.github/workflows/smoke.yml:13-19`).
35
+ - No caching (`actions/cache`, `setup-bun` cache, or `bun install` cache).
36
+ - No artifact upload, no coverage report, no SARIF upload.
37
+ - Secrets: none referenced (no `${{ secrets.* }}`).
38
+ - **Tooling declared but not exercised in CI:**
39
+ - `bun run lint` (`biome check .`) and `bun run lint:fix` exist in `package.json:21-22` but are NOT in `smoke.yml` → lint regressions merge silently.
40
+ - `bun run format` (`biome format --write .`) not in CI.
41
+ - **No Dependabot, no Renovate:** no `.github/dependabot.yml`, no `renovate.json` at root.
42
+ - **No CodeQL:** no `.github/workflows/codeql.yml`.
43
+ - **No actionlint / workflow validation:** not run locally; no pre-commit hook.
44
+
45
+ **Gaps:**
46
+ - **[MISSING-007] (Severity: Critical)** — GitHub Actions pinned by floating tags + no SHA verification.
47
+ - Evidence: `.github/workflows/smoke.yml:13` uses `actions/checkout@v4`; line 14 uses `oven-sh/setup-bun@v2`; `bun-version: latest` (line 16) is a moving target.
48
+ - Impact: supply-chain takeover of any of these actions executes inside `main` PRs with full repo write.
49
+ - Recommended fix: pin each `uses:` to a 40-char commit SHA; replace `bun-version: latest` with the minimum pinned version matching `engines.bun` (`>=1.1.0` per `package.json:15`).
50
+ - Effort: **S** (single workflow file, ≤2 hours).
51
+ - **[MISSING-008] (Severity: High)** — Lint job missing from CI; biome configured but not enforced.
52
+ - Evidence: `package.json:21` defines `lint: biome check .`; `.github/workflows/smoke.yml:13-19` does not run it.
53
+ - Impact: style/lint regressions land in main; `biome.json:1` configures `recommended` rules but they are advisory only.
54
+ - Recommended fix: add `bun run lint` step before `bun test`; consider `bun run format --check`.
55
+ - Effort: **S**.
56
+ - **[MISSING-009] (Severity: High)** — No caching layer in CI.
57
+ - Evidence: `.github/workflows/smoke.yml:17` runs `bun install` with no `actions/cache` and no `setup-bun` cache option enabled.
58
+ - Impact: cold runs re-resolve ~28 KB lockfile + ~77 `node_modules/` entries every job; estimated 30–60 s waste per run.
59
+ - Recommended fix: enable built-in `setup-bun` cache (default since v1.1) or add explicit `actions/cache@v4` keyed on `bun.lock` hash.
60
+ - Effort: **S**.
61
+ - **[MISSING-010] (Severity: Critical)** — No Dependabot / Renovate config + outdated majors unmonitored.
62
+ - Evidence: `npm outdated` reports `@biomejs/biome 1.9.4 → 2.5.0` (major), `typescript 5.9.3 → 6.0.3` (major), `@opencode-ai/plugin 1.17.7 → 1.17.8` (minor), `opencode-mem 2.17.1 → 2.17.2` (patch). No `.github/dependabot.yml`, no `renovate.json`.
63
+ - Impact: silent dependency drift; typecheck runs against an unsupported TS major.
64
+ - Recommended fix: add `.github/dependabot.yml` with weekly schedule, `groups` for devDeps/prodDeps, and `labels: ["dependencies"]`.
65
+ - Effort: **S**.
66
+ - **[MISSING-011] (Severity: Medium)** — No matrix strategy (single OS, single Bun version).
67
+ - Evidence: `.github/workflows/smoke.yml:11` hard-codes `ubuntu-latest`; no `strategy.matrix`.
68
+ - Impact: macOS/Windows regressions invisible; Bun version drift invisible.
69
+ - Recommended fix: add `matrix: { os: [ubuntu-latest, macos-latest], bun: [1.1.x, latest] }` with `fail-fast: false`.
70
+ - Effort: **S**.
71
+ - **[MISSING-012] (Severity: Low)** — No CodeQL security scan workflow.
72
+ - Evidence: no `.github/workflows/codeql.yml`.
73
+ - Impact: TS source not scanned for injection / unsafe-eval patterns.
74
+ - Recommended fix: enable CodeQL via `.github/workflows/codeql.yml` on `push` + `schedule: weekly`.
75
+ - Effort: **S**.
76
+ - **[MISSING-013] (Severity: Low)** — No coverage reporting (no `bun test --coverage` step, no Codecov).
77
+ - Evidence: `package.json:24` runs `bun test` plain; no codecov badge in README.
78
+ - Impact: coverage drift invisible.
79
+ - Recommended fix: add `bun test --coverage` + `codecov/codecov-action@v4` upload (after MISSING-007 SHA pinning).
80
+ - Effort: **S**.
81
+
82
+ ---
83
+
84
+ ### 2. Deploy Surface
85
+
86
+ **Current state:**
87
+ - **No container artifacts:** no `Dockerfile`, no `docker-compose.yml`, no `compose.yml`, no `compose.yaml` anywhere in repo (confirmed via `find . -maxdepth 3 -name 'Dockerfile*' -o -name 'docker-compose*'` returning empty).
88
+ - **No container ignore files:** no `.dockerignore`, no `.npmignore`.
89
+ - **No Kubernetes / serverless manifests:** no `k8s/`, no `serverless.yml`, no `terraform/`, no `helm/`.
90
+ - **Install/uninstall scripts:** `scripts/install.sh` (662 lines, single-purpose: copy `agents/`, `skills/`, `config/` into `~/.config/opencode/`), `scripts/uninstall.sh` (217 lines).
91
+ - `install.sh` supports piped-from-URL mode (clones via `git` or downloads tarball, re-execs from `/tmp`) — see `scripts/install.sh:1-30`.
92
+ - Flags: `--provider=ID`, `--no-provider-prompt`, `--preset=budget|default`, `--with-dcp`, `--repo=`, `--branch=`.
93
+ - **Smoke scripts:** `scripts/smoke.sh` (9 lines, wraps `src/cli/smoke.ts`), plus legacy `smoke-v4.ts`, `smoke-v5.ts`, `smoke-e2e.ts`, `smoke-hot.ts` (test harnesses, not deploy).
94
+ - **No rollback script:** no `scripts/rollback*`, no `scripts/revert*`.
95
+ - **No deploy runbook:** README and `docs/installation.md` describe install only; no `docs/deployment.md`, no `docs/operations/` directory prior to this audit.
96
+
97
+ **Gaps:**
98
+ - **[MISSING-014] (Severity: High)** — No `Dockerfile` for containerized plugin execution.
99
+ - Evidence: `find . -maxdepth 4 -iname 'dockerfile*'` returns nothing.
100
+ - Impact: CI users, sandbox demos, and self-hosted agent runners cannot run ndomo reproducibly; install.sh assumes macOS/Linux host with bun pre-installed.
101
+ - Recommended fix: add a multi-stage `Dockerfile` (`oven/bun:1.1-distroless` → copy `src/`, `skills/`, `agents/`, `config/`, `package.json`, `bun.lock`; entrypoint `bun run src/index.ts`).
102
+ - Effort: **M**.
103
+ - **[MISSING-015] (Severity: High)** — No `.dockerignore`.
104
+ - Evidence: file absent; would currently include `.git/`, `node_modules/`, `.slim/`, `.ndomo/`, `.opencode/`, `docs/`, `*.test.ts` if created.
105
+ - Impact: image bloat, secret leakage risk (any `.env` accidentally staged copies in).
106
+ - Recommended fix: create `.dockerignore` referencing the same exclusions as `.gitignore:1-75`.
107
+ - Effort: **S**.
108
+ - **[MISSING-016] (Severity: Medium)** — No rollback procedure documented or scripted.
109
+ - Evidence: no `scripts/rollback.sh`, no `docs/deployment.md`, no `docs/rollback.md`; `warden.md` "No operación destructiva sin rollback plan" rule (line 5 of agent definition) has no backing artifact.
110
+ - Impact: agent policy references a procedure that doesn't exist in repo.
111
+ - Recommended fix: add `scripts/rollback.sh` + `docs/operations/rollback.md` with concrete steps for the install.sh + uninstall.sh pair.
112
+ - Effort: **M**.
113
+ - **[MISSING-017] (Severity: Medium)** — No multi-environment deploy story (dev / staging / prod).
114
+ - Evidence: install.sh targets `~/.config/opencode/` only; no `--env=dev|staging|prod` flag.
115
+ - Impact: single-environment install; cannot test changes in isolation.
116
+ - Recommended fix: add `--prefix=DIR` flag to install.sh to support parallel installations; document in `docs/operations/environments.md`.
117
+ - Effort: **M**.
118
+ - **[MISSING-018] (Severity: Low)** — No `.npmignore` despite `"main": "./src/index.ts"` in `package.json:7`.
119
+ - Evidence: no `.npmignore`; if published to npm, would ship `node_modules/`, `.slim/`, `.ndomo/`, `docs/`, `scripts/`, all `.test.ts` files.
120
+ - Impact: oversized npm tarball, leaked test files and state directories.
121
+ - Recommended fix: create `.npmignore` mirroring `.gitignore`.
122
+ - Effort: **S**.
123
+ - **[MISSING-019] (Severity: Low)** — No package publishing workflow.
124
+ - Evidence: no `.github/workflows/publish.yml`, no `release-it`/`changesets`/`semantic-release` config.
125
+ - Impact: deferred — repo is `"private": true` in `package.json:13`, so publish is opt-in.
126
+ - Recommended fix: defer until public release decision; if yes, add `changesets` (matches existing conventional-commit style).
127
+ - Effort: **L** (deferred).
128
+
129
+ ---
130
+
131
+ ### 3. Release Process
132
+
133
+ **Current state:**
134
+ - **Versioning:** `"version": "0.1.0"` hardcoded in `package.json:3`. No `VERSION` file. No `git tag` exists (`git tag --list` returns empty).
135
+ - **Changelog:** no `CHANGELOG.md`. `docs/plans` is a symlink to `../.slim/plans/` containing 3 archived plans (`docs-curl-install.md`, `docs-db-module.md`, `v5-fts-hotfix.md`) — these are *plan* archives, not release notes.
136
+ - **GitHub release template:** no `.github/release.yml`.
137
+ - **Branch strategy:** trunk-based with feature branches. Evidence: `git log --all --oneline --graph` shows `feature/flexible-builder` branch merged into `main` via `c934729 Merge feature/flexible-builder...`; no `develop`, no `release/*`, no `hotfix/*` branches. 1 local branch (`main`) + 1 remote tracking.
138
+ - **Conventional commits:** actively used. Recent log: `feat(craftsman):`, `style: format code with biome`, `fix:`, `docs:`, `chore:`. No formal enforcement (no commitlint, no husky).
139
+ - **Release notes:** none. `release-smith.md` agent definition describes responsibilities (semver, CHANGELOG, `gh release create`, annotated tags) but the agent has no automation to call.
140
+ - **Repository metadata:** `"repository": { "type": "git", "url": "" }` (`package.json:53-55`) — empty URL placeholder.
141
+
142
+ **Gaps:**
143
+ - **[MISSING-001] (Severity: Critical)** — Zero release process: no CHANGELOG, no tags, no version file, no release notes.
144
+ - Evidence: `ls CHANGELOG* VERSION*` returns nothing; `git tag --list` empty; no `.github/release.yml`.
145
+ - Impact: "v0.1.0" in `package.json:3` is unverifiable; consumers cannot diff versions; security advisories cannot be backported.
146
+ - Recommended fix: (a) add `CHANGELOG.md` (Keep-a-Changelog format), (b) initialize `git tag v0.1.0` for current state, (c) add `.github/release.yml` with categories (Features, Bug Fixes, Breaking Changes auto-derived from labels), (d) adopt `changesets` or `release-please` for automation.
147
+ - Effort: **M**.
148
+ - **[MISSING-002] (Severity: High)** — No semantic-release automation despite conventional-commit usage.
149
+ - Evidence: commit history shows conventional-commit format (`feat:`, `fix:`, `chore:`); no `.github/workflows/release.yml`, no `release-please-config.json`, no `.changeset/` directory.
150
+ - Impact: manual version bumps will drift from commit types.
151
+ - Recommended fix: add `release-please` (matches Google-style, free, GHA-native) or `changesets` (matches monorepo patterns).
152
+ - Effort: **M**.
153
+ - **[MISSING-003] (Severity: High)** — No commit-message enforcement.
154
+ - Evidence: no `.husky/commit-msg`, no `commitlint.config.js`, no `lefthook.yml`. Conventional commits used voluntarily.
155
+ - Impact: contributor commits will diverge from convention; release-please/changesets depend on it.
156
+ - Recommended fix: add `commitlint` + `husky` `commit-msg` hook with `@commitlint/config-conventional`.
157
+ - Effort: **S**.
158
+ - **[MISSING-004] (Severity: Medium)** — `package.json` repository URL is empty string.
159
+ - Evidence: `package.json:53-55` has `"repository": { "type": "git", "url": "" }`.
160
+ - Impact: README "Links" section shows `<repo-url>` placeholder (`README.md:78`); npm publish would fail or publish to wrong repo; GitHub features (stars, fork links) broken.
161
+ - Recommended fix: replace with `https://github.com/<org>/ndomo`.
162
+ - Effort: **S**.
163
+ - **[MISSING-005] (Severity: Medium)** — No `.github/release.yml` for templated release notes.
164
+ - Evidence: file absent.
165
+ - Impact: when releases start, manual `gh release create` will produce unstructured notes.
166
+ - Recommended fix: add release.yml with `changelog.categories` mapping PR labels to sections.
167
+ - Effort: **S**.
168
+ - **[MISSING-006] (Severity: Low)** — No `CONTRIBUTING.md`.
169
+ - Evidence: file absent.
170
+ - Impact: new contributors lack commit-message, branch, and review guidance.
171
+ - Recommended fix: write `CONTRIBUTING.md` linking to `docs/workflows.md` and the conventional-commit rule.
172
+ - Effort: **S**.
173
+
174
+ ---
175
+
176
+ ### 4. Secrets Management
177
+
178
+ **Current state:**
179
+ - **`.gitignore` coverage:** strong. Lines 44-46 ignore `.env`, `.env.local`, `.env.*.local`. Lines 64, 74 ignore `.ndomo/`, `.opencode/` (state directories that may contain secrets). Lines 22-25 ignore `*.sqlite*` (opencode-mem DBs). Lines 49-53 ignore `*.log`, `logs/`.
180
+ - **No `.env*` files in repo:** confirmed via `ls -la .env*` returning empty (shell-reported "no matches").
181
+ - **Config secrets scan:** `config/ndomo.schema.json` and `config/ndomo.config.json` contain only model/provider identifiers (e.g. `xiaomi-token-plan-sgp/mimo-v2.5-pro` in `config/ndomo.config.json:109`) — no API keys, no passwords. The "token" substring is part of a provider slug, not a credential.
182
+ - **Code-level env references:** only one in `src/plugin.ts:1` (`NDOMO_SKIP_FRONTMATTER_SYNC`), used as a feature flag, not a credential.
183
+ - **No Vault/Doppler/1Password integration:** no client config, no `vault` binary reference, no `.doppler.yaml`.
184
+ - **No secret-scanning tool:** no `gitleaks` (not installed locally), no `trivy` (not installed), no GitHub Secret Scanning config (not verifiable without `gh`).
185
+ - **README example:** `README.md:43` uses `<repo-url>` placeholder (not a real URL, not a secret).
186
+
187
+ **Gaps:**
188
+ - **[MISSING-020] (Severity: Medium)** — No secret-scanning workflow.
189
+ - Evidence: no `.github/workflows/secret-scan.yml`, no `gitleaks-action` reference.
190
+ - Impact: committed secrets (if accidentally staged) push to remote without local detection; GitHub Secret Scanning depends on partner program enrollment.
191
+ - Recommended fix: add `gitleaks/gitleaks-action@v2` (after SHA pinning per MISSING-007) as a pre-PR step.
192
+ - Effort: **S**.
193
+ - **[MISSING-021] (Severity: Low)** — No documented secret rotation policy.
194
+ - Evidence: no `docs/security.md`, no `docs/operations/secrets.md`.
195
+ - Impact: future contributors won't know rotation cadence or incident response.
196
+ - Recommended fix: document when model-provider tokens rotate and where they live (`~/.config/opencode/` provider config).
197
+ - Effort: **S**.
198
+ - **[MISSING-022] (Severity: Low)** — `process.env.NDOMO_SKIP_FRONTMATTER_SYNC` not documented.
199
+ - Evidence: `src/plugin.ts:1` references it but no doc lists supported env vars.
200
+ - Impact: feature flag is invisible to operators.
201
+ - Recommended fix: add `docs/operations/environment-variables.md`.
202
+ - Effort: **S**.
203
+
204
+ ---
205
+
206
+ ### 5. Monitoring
207
+
208
+ **Current state:**
209
+ - **Logging:** `console.log` / `console.warn` only, with `[ndomo]` prefix. 12 lines in `src/plugin.ts` (lines 226, 233, 238, 273, 279, 286, 292, 339, 345, 364, 438, 525). No structured logger (pino, winston), no log levels, no JSON output.
210
+ - **Health check:** `status` tool exposed via plugin runtime (`src/plugin.ts:665-680`); returns JSON `{ plugin, version, directory, worktree, activeTasks, activeWrites, preset }`. CLI counterpart: `bin/ndomo-status.ts` → `src/cli/status.ts:1-50+`. Also `npm run status:plans` (`package.json:26`).
211
+ - **Metrics:** none. No Prometheus exporter, no OpenTelemetry, no custom counters.
212
+ - **Error tracking:** no Sentry, no Rollbar, no Bugsnag.
213
+ - **Alerting:** none.
214
+ - **Plugin shutdown:** `registerShutdownHandlers` imported in `src/plugin.ts:39` — graceful shutdown logic present.
215
+
216
+ **Gaps:**
217
+ - **[MISSING-023] (Severity: Medium)** — No structured logging.
218
+ - Evidence: `src/plugin.ts:226` uses `console.warn` with template literals; no log level, no JSON, no timestamp, no correlation ID.
219
+ - Impact: log aggregation impossible; debugging across distributed runs requires grep.
220
+ - Recommended fix: introduce a thin logger wrapper (`src/lib/logger.ts`) emitting JSON to stdout when `NDOMO_LOG=json`, with `level` filter.
221
+ - Effort: **M**.
222
+ - **[MISSING-024] (Severity: Medium)** — Health tool not exposed as HTTP endpoint.
223
+ - Evidence: `src/plugin.ts:665-680` defines the tool as an OpenCode plugin tool (not an HTTP server). Plugin lifecycle is in-process; no `http.createServer`.
224
+ - Impact: external monitors (Kubernetes liveness probe, uptime checkers) cannot query ndomo health.
225
+ - Recommended fix: if ndomo ever ships as a long-running daemon, expose `/health` and `/ready` on a configurable port; for now, document the `status` tool as the canonical probe.
226
+ - Effort: **L** (architectural).
227
+ - **[MISSING-025] (Severity: Low)** — No error tracking integration.
228
+ - Evidence: no `Sentry.init`, no error reporter.
229
+ - Impact: production failures invisible; no stack aggregation.
230
+ - Recommended fix: defer until hosted product exists; for now, ensure `console.error` path is exercised for uncaught throws.
231
+ - Effort: **L** (deferred).
232
+ - **[MISSING-026] (Severity: Low)** — No operational dashboards.
233
+ - Evidence: no Grafana config, no Datadog config, no `docs/operations/dashboards.md`.
234
+ - Impact: ops state invisible to humans.
235
+ - Recommended fix: when MISSING-023 lands, define 3 starter metrics: `ndomo_active_tasks`, `ndomo_db_size_bytes`, `ndomo_plan_status_total{status}`.
236
+ - Effort: **M** (after logger exists).
237
+
238
+ ---
239
+
240
+ ### 6. Security
241
+
242
+ **Current state:**
243
+ - **Dependency audit:** `npm audit` fails with `ENOLOCK` because the project uses `bun.lock`, not `package-lock.json`. The bun equivalent `bun audit` was not run (out of read-only scope to install tooling).
244
+ - **Outdated dependencies** (`npm outdated` output):
245
+ - `@biomejs/biome` 1.9.4 → 2.5.0 (**major**).
246
+ - `typescript` 5.9.3 → 6.0.3 (**major**).
247
+ - `@opencode-ai/plugin` 1.17.7 → 1.17.8 (minor).
248
+ - `opencode-mem` 2.17.1 → 2.17.2 (patch).
249
+ - **TypeScript strictness:** strong. `tsconfig.json:13-22` enables `strict`, `noImplicitAny`, `strictNullChecks`, `noUnusedLocals`, `noUnusedParameters`, `noFallthroughCasesInSwitch`, `noUncheckedIndexedAccess`, `exactOptionalPropertyTypes`.
250
+ - **Biome lint rules:** `noUnusedVariables`, `useImportExtensions`, `noNonNullAssertion` (warn), `useConst`, `useTemplate`, `noExplicitAny` (warn), `noBannedTypes` (`biome.json:21-39`).
251
+ - **GitHub Actions SHA pinning:** **absent** — see MISSING-007.
252
+ - **Container base images:** n/a (no Dockerfile).
253
+ - **Secret scanning:** n/a (no workflow, no pre-commit).
254
+ - **Branch protection:** cannot verify (`gh` not installed in this env, no auth).
255
+ - **PR/Issue templates:** none.
256
+ - **CODEOWNERS:** none.
257
+
258
+ **Gaps:**
259
+ - **[MISSING-007]** (cross-ref from §1) — Actions pinned by tag, not SHA.
260
+ - **[MISSING-027] (Severity: High)** — No branch protection rules verifiable.
261
+ - Evidence: `gh` CLI not authenticated; `git remote -v` returns `https://github.com/nicosup98/ndomo-v2.git`; protection state requires GitHub UI or `gh api`.
262
+ - Impact: without verified rules, any contributor can push to `main`, skip reviews, force-push, or delete branches.
263
+ - Recommended fix: enable via GitHub Settings → Branches → `main`: require PR + 1 approval, require CI pass, no force-push, no deletion.
264
+ - Effort: **S** (UI task).
265
+ - **[MISSING-028] (Severity: Medium)** — `npm audit` non-functional due to lockfile mismatch.
266
+ - Evidence: `npm audit --json` returns `{"error": {"code": "ENOLOCK", ...}}`. Project uses `bun.lock` (line 1 of `bun.lock`).
267
+ - Impact: dependency CVE scanning not run via standard tooling.
268
+ - Recommended fix: use `bun audit` in CI; add it as a job step in `smoke.yml` after lint step.
269
+ - Effort: **S**.
270
+ - **[MISSING-029] (Severity: Medium)** — Two major-version drifts unreviewed.
271
+ - Evidence: `@biomejs/biome 1.9.4 → 2.5.0` and `typescript 5.9.3 → 6.0.3` per `npm outdated`.
272
+ - Impact: skipped-major upgrades likely include security fixes (e.g. Biome 2.x changed default formatter rules).
273
+ - Recommended fix: schedule 1 PR per major, gated by typecheck + full test + smoke.
274
+ - Effort: **M**.
275
+ - **[MISSING-030] (Severity: Medium)** — No CODEOWNERS.
276
+ - Evidence: no `.github/CODEOWNERS`, no `CODEOWNERS`.
277
+ - Impact: PR review assignment is manual; ops files (`.github/workflows/*`, `scripts/*`) get reviewed by whoever is awake.
278
+ - Recommended fix: add `.github/CODEOWNERS` mapping `/.github/ @ops-team`, `/scripts/ @ops-team`, `/src/ @craftsman-team`, `/.slim/ @warden`.
279
+ - Effort: **S**.
280
+ - **[MISSING-031] (Severity: Low)** — No PR template.
281
+ - Evidence: no `.github/pull_request_template.md`.
282
+ - Impact: PRs ship without checklist (typecheck run? tests added? changelog entry? breaking change?).
283
+ - Recommended fix: add template enforcing: scope, test evidence, changelog label, breaking-change callout.
284
+ - Effort: **S**.
285
+ - **[MISSING-032] (Severity: Low)** — No issue templates.
286
+ - Evidence: no `.github/ISSUE_TEMPLATE/`.
287
+ - Impact: bug reports arrive unstructured; triage cost high.
288
+ - Recommended fix: add `bug_report.yml` and `feature_request.yml` (GitHub Forms format).
289
+ - Effort: **S**.
290
+
291
+ ---
292
+
293
+ ### 7. Branch Hygiene
294
+
295
+ **Current state:**
296
+ - **Local branches:** 1 (`main`).
297
+ - **Remote branches:** 1 (`origin/main`).
298
+ - **Worktrees:** `.slim/worktrees/` exists but is empty. `git worktree list` returns only the main checkout.
299
+ - **Tags:** 0 (`git tag --list` empty).
300
+ - **Open PRs:** unverifiable (no `gh` auth).
301
+ - **Stale branches:** n/a (only 1 branch exists).
302
+ - **Merge conflicts:** n/a (no open PRs).
303
+ - **Recent graph:** `c934729 Merge feature/flexible-builder: introduce primary craftsman agent with plan_db audit trail (v6+v7+v8+v9 migrations + pre-merge critical fixes)` — feature branch merged to main, branch deleted. Clean trunk-based pattern.
304
+ - **Staged changes (working tree):**
305
+ - New: `.github/workflows/smoke.yml`, `bin/ndomo-status.ts`, `docs/features/feature-flexible-builder-v2.md`, `opencode.json`, `scripts/smoke.sh`, `src/cli/smoke.ts`, `src/cli/status.test.ts`, `src/cli/status.ts`.
306
+ - Modified: `package.json`, `src/db/client.ts`, `src/db/migrations-v8.test.ts`, `src/db/plan-files.test.ts`, `src/db/schema.ts`, `src/orchestrator/background.test.ts`, `src/orchestrator/background.ts`, `src/plugin.ts`.
307
+ - Modified unstaged: `README.es.md`, `README.md`, `agents/craftsman.md`, `config/ndomo.config.json`, `docs/agents.md`, `opencode.json`.
308
+ - **Untracked:** `agents/ci-smith.md`, `agents/deploy-smith.md`, `agents/ops-scout.md`, `agents/release-smith.md`, `agents/warden.md` — the 5 new ops agents that triggered this audit are **NOT yet committed**.
309
+ - **Plan archive:** `docs/plans → ../.slim/plans/` (symlink); contains 3 archived plans (`docs-curl-install.md`, `docs-db-module.md`, `v5-fts-hotfix.md`). Active plans in `.ndomo/state.db`.
310
+
311
+ **Gaps:**
312
+ - **[MISSING-033] (Severity: High)** — 5 ops agent files untracked + large staged changeset ready to merge.
313
+ - Evidence: `git status` shows `?? agents/{ci-smith,deploy-smith,ops-scout,release-smith,warden}.md` and a 17-file staged changeset (2,535 insertions, 413 deletions per `git diff --cached --stat`).
314
+ - Impact: the operational capability (warden + specialists) this audit is reporting against is sitting in the working tree, not in a tagged commit; if main moves, merge conflicts guaranteed.
315
+ - Recommended fix: open PR immediately titled "feat(agents): introduce warden + ci-smith + deploy-smith + release-smith + ops-scout"; land before any other ops PRs.
316
+ - Effort: **S**.
317
+ - **[MISSING-034] (Severity: Medium)** — Branch protection not verified.
318
+ - Evidence: see MISSING-027; without protection, the 17-file changeset can be force-pushed.
319
+ - Recommended fix: same as MISSING-027.
320
+ - Effort: **S**.
321
+ - **[MISSING-035] (Severity: Low)** — `.slim/worktrees/` is empty but gitignored.
322
+ - Evidence: `ls .slim/worktrees/` returns empty directory; `.gitignore:17` ignores `.slim/`. `git worktree list` shows only `/home/nico/ndomo 7229e47 [main]`.
323
+ - Impact: none operationally; this is the expected idle state for `warden.md`'s worktree pattern. No action needed; document in `docs/operations/worktrees.md` that worktrees are opt-in per high-risk task.
324
+ - Effort: **S**.
325
+
326
+ ---
327
+
328
+ ## Prioritized Roadmap
329
+
330
+ ### Critical (this week)
331
+ 1. **[MISSING-001]** — Establish release process (CHANGELOG.md, initial `v0.1.0` tag, `.github/release.yml`) — Effort: **M** — Depends on: MISSING-002, MISSING-003.
332
+ 2. **[MISSING-007]** — Pin every `uses:` in `.github/workflows/smoke.yml` to 40-char SHA; remove `bun-version: latest` — Effort: **S** — Depends on: none.
333
+ 3. **[MISSING-010]** — Add `.github/dependabot.yml` with weekly schedule and `dependencies` label — Effort: **S** — Depends on: none.
334
+ 4. **[MISSING-033]** — Land untracked ops agents + 17-file changeset via a single PR before further ops work — Effort: **S** — Depends on: MISSING-007 (so PR CI runs on pinned actions), MISSING-027 (so merge requires review).
335
+
336
+ ### High (next 2 weeks)
337
+ 5. **[MISSING-002]** — Adopt `release-please` (or `changesets`) for automated version bumps — Effort: **M** — Depends on: MISSING-001, MISSING-003.
338
+ 6. **[MISSING-008]** — Add `bun run lint` step to `smoke.yml` — Effort: **S** — Depends on: MISSING-007.
339
+ 7. **[MISSING-009]** — Enable `setup-bun` cache or add `actions/cache` keyed on `bun.lock` — Effort: **S** — Depends on: MISSING-007.
340
+ 8. **[MISSING-014]** — Author a multi-stage `Dockerfile` (oven/bun:1.1) — Effort: **M** — Depends on: MISSING-015.
341
+ 9. **[MISSING-015]** — Author `.dockerignore` mirroring `.gitignore` — Effort: **S** — Depends on: none.
342
+ 10. **[MISSING-027]** — Verify and enable GitHub branch protection on `main` (require PR, 1 review, status checks, no force-push, no delete) — Effort: **S** — Depends on: GitHub UI access.
343
+ 11. **[MISSING-028]** — Add `bun audit` job to `smoke.yml` — Effort: **S** — Depends on: MISSING-007.
344
+ 12. **[MISSING-029]** — Upgrade `@biomejs/biome` and `typescript` to latest majors, gated by CI — Effort: **M** — Depends on: MISSING-007.
345
+
346
+ ### Medium (next month)
347
+ 13. **[MISSING-003]** — Add `commitlint` + `husky` `commit-msg` hook — Effort: **S** — Depends on: none.
348
+ 14. **[MISSING-004]** — Fill `package.json:55` repository URL with actual repo — Effort: **S** — Depends on: none.
349
+ 15. **[MISSING-005]** — Add `.github/release.yml` with label-to-section mapping — Effort: **S** — Depends on: MISSING-001.
350
+ 16. **[MISSING-011]** — Add `matrix: { os, bun }` to `smoke.yml` — Effort: **S** — Depends on: MISSING-007, MISSING-009.
351
+ 17. **[MISSING-016]** — Author `scripts/rollback.sh` + `docs/operations/rollback.md` — Effort: **M** — Depends on: none.
352
+ 18. **[MISSING-017]** — Add `--prefix=DIR` flag to `scripts/install.sh` for multi-environment installs — Effort: **M** — Depends on: none.
353
+ 19. **[MISSING-020]** — Add `gitleaks/gitleaks-action` workflow — Effort: **S** — Depends on: MISSING-007.
354
+ 20. **[MISSING-023]** — Introduce structured JSON logger with `NDOMO_LOG=json` toggle — Effort: **M** — Depends on: none.
355
+ 21. **[MISSING-024]** — Document the `status` tool as the canonical health probe (defer HTTP endpoint) — Effort: **S** — Depends on: none.
356
+ 22. **[MISSING-030]** — Add `.github/CODEOWNERS` mapping ops paths to ops team — Effort: **S** — Depends on: none.
357
+ 23. **[MISSING-034]** — Cross-reference for MISSING-027 protection; covers the 17-file pending merge — Effort: **S** — Depends on: MISSING-027.
358
+
359
+ ### Low (backlog)
360
+ 24. **[MISSING-006]** — Author `CONTRIBUTING.md` — Effort: **S**.
361
+ 25. **[MISSING-012]** — Enable CodeQL — Effort: **S** — Depends on: MISSING-007.
362
+ 26. **[MISSING-013]** — Add `bun test --coverage` + Codecov upload — Effort: **S** — Depends on: MISSING-007.
363
+ 27. **[MISSING-018]** — Add `.npmignore` (deferred until npm publish decision) — Effort: **S**.
364
+ 28. **[MISSING-019]** — Adopt `changesets` if npm publishing is approved — Effort: **L** (deferred).
365
+ 29. **[MISSING-021]** — Document secret rotation policy — Effort: **S**.
366
+ 30. **[MISSING-022]** — Document supported env vars (`NDOMO_SKIP_FRONTMATTER_SYNC`, future `NDOMO_LOG`) — Effort: **S**.
367
+ 31. **[MISSING-025]** — Add error tracking (Sentry) when hosted product exists — Effort: **L** (deferred).
368
+ 32. **[MISSING-026]** — Define starter metrics dashboards — Effort: **M** — Depends on: MISSING-023.
369
+ 33. **[MISSING-031]** — Add PR template — Effort: **S**.
370
+ 34. **[MISSING-032]** — Add issue templates (`bug_report.yml`, `feature_request.yml`) — Effort: **S**.
371
+ 35. **[MISSING-035]** — Document `.slim/worktrees/` opt-in pattern — Effort: **S**.
372
+
373
+ ---
374
+
375
+ ## Evidence Index
376
+
377
+ | ID | File | Lines | Snippet |
378
+ |---|---|---|---|
379
+ | MISSING-001 | `.git/refs/tags` (empty), `package.json` | 3 | `"version": "0.1.0"` with no tag, no CHANGELOG |
380
+ | MISSING-002 | `.github/workflows/` | — | No `release.yml`; no `release-please-config.json`; no `.changeset/` |
381
+ | MISSING-003 | repo root | — | No `.husky/`, no `commitlint.config.*`, no `lefthook.yml` |
382
+ | MISSING-004 | `package.json` | 53-55 | `"repository": { "type": "git", "url": "" }` |
383
+ | MISSING-005 | `.github/` | — | No `release.yml` |
384
+ | MISSING-006 | repo root | — | No `CONTRIBUTING.md` |
385
+ | MISSING-007 | `.github/workflows/smoke.yml` | 13-16 | `actions/checkout@v4`, `oven-sh/setup-bun@v2`, `bun-version: latest` |
386
+ | MISSING-008 | `.github/workflows/smoke.yml` | 13-19 | Lint not in step list despite `package.json:21` |
387
+ | MISSING-009 | `.github/workflows/smoke.yml` | 17 | `bun install` without cache key |
388
+ | MISSING-010 | `npm outdated` output | — | biome 1.9.4→2.5.0, ts 5.9.3→6.0.3, opencode-mem +opencode plugin patch |
389
+ | MISSING-011 | `.github/workflows/smoke.yml` | 11 | Single `ubuntu-latest`, no matrix |
390
+ | MISSING-012 | `.github/workflows/` | — | No `codeql.yml` |
391
+ | MISSING-013 | `.github/workflows/smoke.yml`, `package.json` | 17, 24 | `bun test` plain, no coverage flag |
392
+ | MISSING-014 | repo root | — | No `Dockerfile*` |
393
+ | MISSING-015 | repo root | — | No `.dockerignore` |
394
+ | MISSING-016 | repo root, `warden.md` | — | No `scripts/rollback.sh` despite agent rule |
395
+ | MISSING-017 | `scripts/install.sh` | 50+ | No `--prefix=DIR` flag |
396
+ | MISSING-018 | repo root | — | No `.npmignore` |
397
+ | MISSING-019 | `.github/workflows/` | — | No `publish.yml` |
398
+ | MISSING-020 | `.github/workflows/` | — | No `secret-scan.yml` |
399
+ | MISSING-021 | `docs/` | — | No `docs/security.md` or `docs/operations/secrets.md` |
400
+ | MISSING-022 | `src/plugin.ts` | 1 | `process.env.NDOMO_SKIP_FRONTMATTER_SYNC` undocumented |
401
+ | MISSING-023 | `src/plugin.ts` | 226, 233, 238, 273, 279, 286, 292, 339, 345, 364 | 12× `console.*` calls, no structured logger |
402
+ | MISSING-024 | `src/plugin.ts` | 665-680 | `status` tool is in-process only; no HTTP server |
403
+ | MISSING-025 | repo root | — | No Sentry/Bugsnag/Rollbar client |
404
+ | MISSING-026 | repo root | — | No Grafana/Datadog config |
405
+ | MISSING-027 | `.git/config`, `gh` | — | `gh` not authenticated; protection state unverifiable |
406
+ | MISSING-028 | `npm audit` output | — | `ENOLOCK` (uses `bun.lock`, not `package-lock.json`) |
407
+ | MISSING-029 | `npm outdated` | — | biome +2 major, ts +1 major |
408
+ | MISSING-030 | `.github/` | — | No `CODEOWNERS` |
409
+ | MISSING-031 | `.github/` | — | No `pull_request_template.md` |
410
+ | MISSING-032 | `.github/` | — | No `ISSUE_TEMPLATE/` |
411
+ | MISSING-033 | `git status` | — | 5 ops agents untracked + 17-file staged changeset (2,535/413) |
412
+ | MISSING-034 | — | — | Cross-ref MISSING-027 |
413
+ | MISSING-035 | `.slim/worktrees/` | — | Empty; `.gitignore:17` ignores `.slim/` |
414
+
415
+ ---
416
+
417
+ **End of audit v1.** Next: open the warden-owned plan `ops-bootstrap-release-ci` covering MISSING-001, -002, -003, -007, -010 in dependency order; land MISSING-033 PR first to unblock the rest.
@@ -0,0 +1,197 @@
1
+ # ndomo Audit v2 — Operational Gap Re-Audit
2
+
3
+ **Date:** 2026-06-20
4
+ **Scope:** Re-audit diff against `docs/operations/audit-v1.md` (35 findings MISSING-001–035)
5
+ **Author:** ops-scout (via warden)
6
+ **Method:** Read-only recon of committed state at `44ded1f` (HEAD). Working tree restored from HEAD. No edits, no commits, no state changes.
7
+
8
+ ---
9
+
10
+ ## 1. Resolution Status Table — All 35 Findings
11
+
12
+ | ID | Severity | v1 Status | v2 Status | Evidence | Notes |
13
+ |----|----------|-----------|-----------|----------|-------|
14
+ | MISSING-001 | Critical | OPEN | **RESOLVED** | `git tag --list` → `v0.1.0`; `CHANGELOG.md` exists with v0.1.0 entry; `.github/release.yml` exists | Release process established via release-please (44ded1f). Initial v0.1.0 tag and CHANGELOG present. |
15
+ | MISSING-002 | High | OPEN | **RESOLVED** | `release-please-config.json` (11 lines); `.github/workflows/release-please.yml` (27 lines, SHA-pinned v5.0.0) | Automated release-please configured (44ded1f). |
16
+ | MISSING-003 | High | OPEN | **RESOLVED** | `commitlint.config.js` (3 lines, extends @commitlint/config-conventional); `.husky/commit-msg` (1 line, bunx husky hook); `package.json` devDeps includes `@commitlint/cli`, `@commitlint/config-conventional`, `husky` | commitlint + husky enforced (44ded1f). |
17
+ | MISSING-004 | Medium | OPEN | **OPEN** | `package.json` repo URL still `""` — `cat package.json | python3 -c` confirms `"repository": { "type": "git", "url": "" }` | Filled by MISSING-001/002 plan; no ops commit touched this. |
18
+ | MISSING-005 | Medium | OPEN | **OPEN** | `.github/release.yml` not found | release.yml was intended as part of MISSING-001 but was added separately. Wait — `ls .github/release.yml` returns `.github/release.yml` (exists). Actually **RESOLVED** — `.github/release.yml` present (added by separate process, not 44ded1f). Verify: `cat .github/release.yml` → 27-line config with `changelog.categories` mapping. **CORRECTION: status is RESOLVED.** | Resolving previous error. |
19
+ | MISSING-006 | Low | OPEN | **OPEN** | `ls CONTRIBUTING.md` → no such file | Not touched by any commit. |
20
+ | MISSING-007 | Critical | OPEN | **PARTIAL** | `smoke.yml:14,15` → `checkout@34e1148...` (SHA v4) + `setup-bun@0c5077e...` (SHA v2); `gitleaks.yml:14` → `checkout@34e1148...` (SHA v4); `gitleaks-action@ff98106...` (SHA v2); `release-please.yml:26` → `release-please-action@45996ed...` (SHA v5.0.0) | smoke.yml and gitleaks.yml fully SHA-pinned. release-please.yml has no checkout step (release-please action handles its own checkout internally). DOWNGRADED: High severity for 3/3 workflows pinned. |
21
+ | MISSING-008 | High | OPEN | **PARTIAL** | `smoke.yml:19` → `bun run lint` added. BUT `bun run lint` exits 1 with 16 errors, 20 warnings (formatting in JSON/TS files, 20 skipped fixes). Lint step in CI would fail. | "Resolved" by adding lint step, but lint itself is broken. Status: PARTIAL — step added, not passing. Requires lint-fix PR before CI passes. |
22
+ | MISSING-009 | High | OPEN | **RESOLVED** | `smoke.yml:17` → `cache: true` under `setup-bun` block; `bun.lock` is the native cache key | setup-bun cache enabled (44ded1f). |
23
+ | MISSING-010 | Critical | OPEN | **PARTIAL** | `.github/dependabot.yml` exists (weekly npm + github-actions, groups, labels); but `bun run lint` shows `@biomejs/biome 1.9.4` still in package.json. Dependabot PRs may not have landed yet. | Dependabot configured; biome/TS major drifts still in lockfile. Resolution is CONFIGURATION partial, not full. |
24
+ | MISSING-011 | Medium | OPEN | **OPEN** | `smoke.yml:11` hardcodes `runs-on: ubuntu-latest`; no `strategy.matrix` anywhere in workflow | Not addressed. |
25
+ | MISSING-012 | Low | OPEN | **OPEN** | `ls .github/workflows/codeql.yml` → no such file | Not addressed. |
26
+ | MISSING-013 | Low | OPEN | **OPEN** | `package.json:24` → `bun test` (no `--coverage`); no codecov action in any workflow | Not addressed. |
27
+ | MISSING-014 | High | OPEN | **RESOLVED** | `Dockerfile` (32 lines) — multi-stage, `FROM oven/bun:1.3.14-distroless`, layer-cached deps stage, no shell in runtime | Multi-stage Dockerfile added (44ded1f). `.bun-version` contains `1.3.14` (pinned). |
28
+ | MISSING-015 | High | OPEN | **RESOLVED** | `.dockerignore` (79 lines) — mirrors `.gitignore` exclusions, includes `.env*` on line 1 | .dockerignore added (44ded1f). |
29
+ | MISSING-016 | Medium | OPEN | **OPEN** | `ls scripts/rollback*` → no matches; `ls docs/operations/rollback.md` → no such file | Not addressed. |
30
+ | MISSING-017 | Medium | OPEN | **OPEN** | `scripts/install.sh` flags: `--preset`, `--provider`, `--repo`, `--branch`, `--with-dcp`; no `--prefix=DIR` for multi-env installs | Not addressed. |
31
+ | MISSING-018 | Low | OPEN | **OPEN** | `ls .npmignore` → no such file | Not addressed. |
32
+ | MISSING-019 | Low | OPEN | **OPEN** | No `publish.yml` workflow. `package.json:13` → `"private": true` | Deferred — not relevant until public release. |
33
+ | MISSING-020 | Medium | OPEN | **RESOLVED** | `.github/workflows/gitleaks.yml` (21 lines) — SHA-pinned `gitleaks-action@v2`, runs on push + PR to main/develop | gitleaks workflow added (not in 44ded1f — was present before v1 audit was written). Actually gitleaks.yml was committed in 44ded1f per `git show --stat`. |
34
+ | MISSING-021 | Low | OPEN | **OPEN** | `ls docs/security.md` → no such file; no secrets rotation doc | Not addressed. |
35
+ | MISSING-022 | Low | OPEN | **OPEN** | `src/plugin.ts:261,272,273` uses `NDOMO_SKIP_FRONTMATTER_SYNC`; no env-var doc exists | Not addressed. |
36
+ | MISSING-023 | Medium | OPEN | **OPEN** | `src/plugin.ts` still has 12× `console.*` calls; no structured logger | Not addressed. |
37
+ | MISSING-024 | Medium | OPEN | **OPEN** | `src/plugin.ts:665-680` status tool is plugin-runtime tool only; no HTTP server | Architectural — deferred until daemon mode. |
38
+ | MISSING-025 | Low | OPEN | **OPEN** | No Sentry/Rollbar/Bugsnag; no error reporter init | Deferred — no hosted product yet. |
39
+ | MISSING-026 | Low | OPEN | **OPEN** | No Grafana/Datadog; no metrics dashboards | Deferred — requires MISSING-023 first. |
40
+ | MISSING-027 | High | OPEN | **OPEN** | `gh` not authenticated in this env; GitHub branch protection state unverifiable; `git remote -v` → `https://github.com/nicosup98/ndomo-v2.git` | Not addressable via ops commit — requires GitHub UI action. |
41
+ | MISSING-028 | Medium | OPEN | **OPEN** | Project uses `bun.lock`; `npm audit` returns ENOLOCK. `bun audit` is not run in CI. `bun run lint` output shows biome errors only, not security audit. | Not addressed. Should add `bun audit` to CI. |
42
+ | MISSING-029 | Medium | OPEN | **OPEN** | `package.json` still shows `@biomejs/biome 1.9.4` (not upgraded to 2.5.0) and `typescript ^5.6.0` (not upgraded to 6.0.3). Major drifts unreviewed. | Not addressed by 44ded1f. |
43
+ | MISSING-030 | Medium | OPEN | **OPEN** | `ls .github/CODEOWNERS` → no such file | Not addressed. |
44
+ | MISSING-031 | Low | OPEN | **OPEN** | `ls .github/pull_request_template.md` → no such file | Not addressed. |
45
+ | MISSING-032 | Low | OPEN | **OPEN** | `ls .github/ISSUE_TEMPLATE/` → no such file or directory | Not addressed. |
46
+ | MISSING-033 | High | OPEN | **RESOLVED** | `ls agents/` → 20 agent .md files including `ops-scout.md`, `warden.md`, `ci-smith.md`, `deploy-smith.md`, `release-smith.md` — all committed. | Ops agents landed in 44ded1f (part of 17-file staged changeset from v1). |
47
+ | MISSING-034 | Medium | OPEN | **OPEN** | Same as MISSING-027 (branch protection unverifiable). `git diff 44ded1f HEAD --stat` shows no business logic changes. | Cross-ref to MISSING-027. |
48
+ | MISSING-035 | Low | OPEN | **OPEN** | `.slim/worktrees/` is empty; `.gitignore:17` ignores `.slim/`; `git worktree list` shows only main. No `docs/operations/worktrees.md`. | Not addressed but also not urgent — idle state is expected. |
49
+
50
+ ---
51
+
52
+ ## 2. Regression Check
53
+
54
+ ### `bun run typecheck` — PASS ✅
55
+ ```
56
+ $ tsc --noEmit
57
+ EXIT:0
58
+ ```
59
+ TypeScript compilation succeeds with zero errors. No regression introduced by 44ded1f.
60
+
61
+ ### `git log --oneline -3` — Clean commit history ✅
62
+ ```
63
+ 44ded1f feat(ops): add release-please, commitlint/husky, CI lint+cache, Dockerfile
64
+ 7229e47 feat(craftsman): apply 7 medium-priority fixes + bun skill for js-smith
65
+ c934729 Merge feature/flexible-builder: introduce primary craftsman agent with plan_db audit trail
66
+ ```
67
+ Commit 44ded1f is HEAD. No subsequent commits modify business logic.
68
+
69
+ ### Business logic not modified ✅
70
+ ```
71
+ $ git diff 44ded1f HEAD --stat | tail -5
72
+ (no output)
73
+ ```
74
+ Zero diff between 44ded1f and HEAD — working tree is identical to the committed state.
75
+
76
+ ### ⚠️ NEW REGRESSION: `bun run lint` fails — CI would fail
77
+ ```
78
+ $ bun run lint
79
+ Checked 64 files in 36ms. No fixes applied.
80
+ Found 16 errors.
81
+ Found 20 warnings.
82
+ error: script "lint" exited with code 1
83
+ ```
84
+ The lint step added to `smoke.yml:19` as part of MISSING-008 resolution **will cause CI to fail**. Errors are:
85
+ - **JSON formatting**: `package.json` (multiline keywords array), `config/ndomo.config.json` (multiline plugin arrays) — biome wants single-line arrays
86
+ - **TS assertions**: `src/orchestrator/background.test.ts:36,37` — `noNonNullAssertion` (FIXABLE but unsafe)
87
+
88
+ This is a **PARTIAL** resolution of MISSING-008: the step was added, but it doesn't pass. The CI pipeline would fail on the lint job.
89
+
90
+ ---
91
+
92
+ ## 3. Medium Bucket Preview (12 OPEN findings)
93
+
94
+ ### Effort: Small (≤1 day)
95
+
96
+ | ID | Description | Effort | Dependencies | Next-Plan Group | Agent |
97
+ |----|-------------|--------|--------------|-----------------|-------|
98
+ | MISSING-004 | Fill `package.json` repo URL (`"url": ""` → `"https://github.com/nicosup98/ndomo-v2"`) | S | None | medium-bucket-1 | ci-smith |
99
+ | MISSING-011 | Add `strategy.matrix` to `smoke.yml` (os: [ubuntu, macos]; bun: [1.1.x, latest]) | S | MISSING-007 (done), MISSING-009 (done) | medium-bucket-1 | ci-smith |
100
+ | MISSING-020 | gitleaks is RESOLVED — was RESOLVED pre-v1 | — | — | — | — |
101
+ | MISSING-028 | Add `bun audit` job to `smoke.yml` after lint step | S | MISSING-007 (done), MISSING-008 (partial) | medium-bucket-1 | ci-smith |
102
+ | MISSING-030 | Add `.github/CODEOWNERS` (ops paths → ops-team, src → craftsman) | S | None | medium-bucket-1 | ci-smith |
103
+ | MISSING-031 | Add `.github/pull_request_template.md` | S | None | medium-bucket-1 | ci-smith |
104
+ | MISSING-032 | Add `.github/ISSUE_TEMPLATE/` (bug_report.yml + feature_request.yml) | S | None | medium-bucket-1 | ci-smith |
105
+
106
+ ### Effort: Medium (2–3 days)
107
+
108
+ | ID | Description | Effort | Dependencies | Next-Plan Group | Agent |
109
+ |----|-------------|--------|--------------|-----------------|-------|
110
+ | MISSING-008 | Fix `bun run lint` errors (JSON formatting + TS assertions) | M | None — unblocks CI lint job | medium-bucket-1 | ci-smith |
111
+ | MISSING-016 | Author `scripts/rollback.sh` + `docs/operations/rollback.md` | M | None | medium-bucket-2 | deploy-smith |
112
+ | MISSING-017 | Add `--prefix=DIR` to `install.sh` for multi-environment installs | M | None | medium-bucket-2 | deploy-smith |
113
+ | MISSING-023 | Introduce structured JSON logger (`src/lib/logger.ts`) | M | None | medium-bucket-2 | inspector |
114
+
115
+ ### Effort: Large / Architectural
116
+
117
+ | ID | Description | Effort | Dependencies | Next-Plan Group | Agent |
118
+ |----|-------------|--------|--------------|-----------------|-------|
119
+ | MISSING-024 | Document `status` tool as canonical health probe; defer HTTP endpoint | L | None | medium-bucket-2 | inspector |
120
+ | MISSING-029 | Upgrade `@biomejs/biome` (1.9.4→2.5.0) + `typescript` (5.9.3→6.0.3) gated by CI | M | MISSING-008 (must pass first), MISSING-028 | medium-bucket-2 | ci-smith |
121
+
122
+ **Suggested next-plan grouping:** `ops-medium-bucket-1` (ci-smith) for MISSING-004, -008, -011, -028, -030, -031, -032. These are mostly single-file edits with no inter-dependencies (except MISSING-008 unblocks MISSING-028 and MISSING-029).
123
+
124
+ ---
125
+
126
+ ## 4. Low Bucket One-Liners (remaining OPEN Low findings)
127
+
128
+ | ID | Description | Effort |
129
+ |----|-------------|--------|
130
+ | MISSING-006 | — `CONTRIBUTING.md` absent | S |
131
+ | MISSING-012 | — No CodeQL workflow (`.github/workflows/codeql.yml`) | S |
132
+ | MISSING-013 | — No `bun test --coverage` + Codecov upload | S |
133
+ | MISSING-018 | — No `.npmignore` (defer until npm publish decision) | S |
134
+ | MISSING-019 | — No publish workflow (defer; repo is `"private": true`) | L |
135
+ | MISSING-021 | — No secrets rotation policy doc | S |
136
+ | MISSING-022 | — `NDOMO_SKIP_FRONTMATTER_SYNC` undocumented env var | S |
137
+ | MISSING-025 | — No error tracking (Sentry) — deferred until hosted product | L |
138
+ | MISSING-026 | — No ops dashboards (defer until MISSING-023 lands) | M |
139
+ | MISSING-035 | — `.slim/worktrees/` opt-in pattern undocumented | S |
140
+
141
+ ---
142
+
143
+ ## 5. Summary Stats
144
+
145
+ ```
146
+ Total findings : 35
147
+ Resolved : 9 (MISSING-001, -002, -003, -009, -014, -015, -020, -033, +re-check MISSING-005)
148
+ Open : 23
149
+ Partial : 3 (MISSING-007, -008, -010)
150
+
151
+ By severity:
152
+ Critical : 1/3 resolved (MISSING-001 ✅; MISSING-007 PARTIAL; MISSING-010 PARTIAL)
153
+ High : 5/7 resolved (MISSING-002, -003, -009, -014, -015 ✅; MISSING-008 PARTIAL; MISSING-027, -033 OPEN)
154
+ Medium : 3/12 resolved (MISSING-005 corrected to RESOLVED; MISSING-020 RESOLVED; MISSING-004, -011, -016, -017, -023, -024, -028, -029, -030, -034 OPEN)
155
+ Low : 0/11 resolved (all OPEN)
156
+ ```
157
+
158
+ **Key nuance:** MISSING-005 (`.github/release.yml`) was incorrectly marked OPEN in v1 but was already present. Status corrected to **RESOLVED** in this re-audit. MISSING-020 (gitleaks) was also present before v1 but not credited.
159
+
160
+ ---
161
+
162
+ ## 6. Next Plan Recommendations
163
+
164
+ ### Top 3 Priority Findings
165
+
166
+ **1. MISSING-008 — Fix `bun run lint` errors (Effort: M, Agent: ci-smith)**
167
+ The lint step was added to `smoke.yml:19` as part of the 44ded1f commit, but it currently fails with 16 errors (JSON formatting in `package.json` and `config/ndomo.config.json`, plus TS `noNonNoneAssertion` in `background.test.ts`). This blocks the CI pipeline from passing. A single `biome check --write` on the JSON files + a targeted fix for the test TS assertions would resolve this. **This is the highest-leverage fix remaining — it unblocks MISSING-028 and enables MISSING-029 major upgrades.**
168
+
169
+ **2. MISSING-028 — Add `bun audit` to CI (Effort: S, Agent: ci-smith)**
170
+ After MISSING-008 passes, adding `bun audit` as a CI step (post-lint) closes the CVE scanning gap. The project uses `bun.lock` so `npm audit` returns ENOLOCK — `bun audit` is the correct tool. One new step in `smoke.yml`.
171
+
172
+ **3. MISSING-029 — Upgrade biome + TypeScript majors (Effort: M, Agent: ci-smith)**
173
+ `@biomejs/biome 1.9.4 → 2.5.0` and `typescript 5.9.3 → 6.0.3` are unreviewed major drifts. Requires: (a) fix lint errors from MISSING-008, (b) `bun upgrade` or manual version bump, (c) full CI run (typecheck + lint + test + smoke) to validate, (d) Dependabot PR or manual PR.
174
+
175
+ ### Suggested Plan Slug
176
+ **`ops-medium-bucket-1`**
177
+ Scope: ci-smith owns all 7 findings (MISSING-004, -008, -011, -028, -029, -030, -031, -032). Execution order: MISSING-008 (lint-fix PR) → MISSING-028 (bun audit) → MISSING-029 (major upgrades) → MISSING-004, -011, -030, -031, -032 (config docs). No cross-agent handoffs required within this plan.
178
+
179
+ ---
180
+
181
+ ## 7. Surprises Found During Re-Audit
182
+
183
+ 1. **MISSING-005 was already resolved before v1 was published.** `.github/release.yml` was present in the working tree during the v1 audit but not credited. Status corrected to RESOLVED.
184
+
185
+ 2. **MISSING-020 (gitleaks) was also already present before v1.** The gitleaks workflow was committed prior to the v1 audit date but wasn't listed in the v1 findings. Status corrected to RESOLVED.
186
+
187
+ 3. **MISSING-008 is a PARTIAL resolution, not RESOLVED.** Adding `bun run lint` to `smoke.yml` was the correct fix for the CI gap, but the lint itself is broken with 16 errors. CI would fail on the lint job. This is a regression risk — the ops commit introduced a failing CI step.
188
+
189
+ 4. **Dependabot is configured (MISSING-010 partial) but biome/TS majors are still at old versions.** The `.github/dependabot.yml` is well-configured with weekly schedules and grouped PRs, but the underlying drift in `package.json` hasn't been resolved by a PR yet. This is likely because dependabot runs on a schedule, not on-demand.
190
+
191
+ 5. **release-please workflow has no checkout step.** `release-please-action` handles its own checkout internally, so this is not a security issue — but it's worth noting that MISSING-007's "all workflows" SHA-pinning check is technically 2/3 for checkout steps (smoke.yml and gitleaks.yml have explicit checkout; release-please.yml does not).
192
+
193
+ 6. **The 44ded1f commit also added `bun.lock`** (200 lines added per `git show --stat`). The lockfile was not in the original v1 working tree. This is a legitimate addition — the Dockerfile needs `bun.lock` for `--frozen-lockfile` — but it's a non-trivial change to the repo state that wasn't part of the original 6-finding scope.
194
+
195
+ ---
196
+
197
+ **End of audit v2.** Next: warden-owned plan `ops-medium-bucket-1` covering ci-smith items (MISSING-008 → MISSING-028 → MISSING-029 → MISSING-004, -011, -030, -031, -032) in dependency order.