{
  "version": "0.5.0-beta.12",
  "description": "Phase 1.3 is now agent-curated. `task.py init-context` removed; `task.py create` seeds `implement.jsonl` / `check.jsonl` with a self-describing `_example` line on sub-agent-capable platforms, and the AI fills real spec + research entries per workflow.md Phase 1.3. Session-start READY gate across 4 implementations now requires at least one curated entry, not just file existence. Skill Routing tables split per-platform — sub-agent platforms no longer see `trellis-before-dev`. Fixes `trellis update` backup-phase stack-overflow on repos with nested `.backup-*/.opencode/node_modules`. Release pipeline hardened with manifest-continuity guard + guards against overwriting published manifests. Restored the missing `0.5.0-beta.10.json` manifest. Not breaking; existing tasks keep working.",
  "breaking": false,
  "recommendMigrate": false,
  "changelog": "**Behavioral changes:**\n- feat(workflow): Phase 1.3 rewritten from \"run `task.py init-context`\" to \"AI curates jsonl directly\". New rule — `implement.jsonl` / `check.jsonl` hold spec + research paths only, never code paths. `task.py create` seeds each jsonl with one self-describing `{\"_example\": \"...\"}` line on sub-agent-capable platforms (Claude / Cursor / Codex / Kiro / Gemini / OpenCode / Qoder / CodeBuddy / Droid / Copilot). Agent-less platforms (Kilo / Antigravity / Windsurf) skip seeding and load specs via the `trellis-before-dev` skill as before.\n- fix(task.py): `init-context` subcommand removed. Invoking it exits 2 with a deprecation message pointing at workflow.md Phase 1.3 and `task.py add-context` for ergonomic editing. `cmd_init_context`, `get_implement_backend`, `get_implement_frontend`, `get_check_context` deleted from `common/task_context.py`.\n- fix(session-start): READY detection requires at least one jsonl row with a `file` key. Seed-only jsonl now surfaces as `Status: PLANNING (Phase 1.3)` with Next-Action pointing at the curate step. Applied across all four implementations: `shared-hooks/session-start.py` (Claude / Cursor / Kiro / CodeBuddy / Droid / Gemini / Qoder), `codex/hooks/session-start.py`, `copilot/hooks/session-start.py`, `opencode/plugins/session-start.js`.\n- feat(workflow.md): Skill Routing and DO-NOT-skip tables split into `[Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]` and `[Kilo, Antigravity, Windsurf]` variants. Sub-agent platforms no longer surface `trellis-before-dev` in the routing table — the main-thread job on those platforms is to dispatch `trellis-implement`, not load spec skills.\n- feat(shared-hooks): `inject-subagent-context.py:read_jsonl_entries` emits a single stderr warning when the jsonl is missing or contains only seed rows, so Class-1 platforms have a clear debug signal instead of silent empty injection.\n- feat(configurators/shared.ts): Class-2 pull-based prelude (Codex / Copilot / Gemini / Qoder) now teaches sub-agents to skip rows without a `file` field and fall back to prd.md + self-discovered specs when the jsonl has only a seed row.\n\n**Bug fixes:**\n- fix(update): `trellis update` no longer crashes with `Maximum call stack size exceeded` during the backup phase. Root cause: `createFullBackup` descended into old `.trellis/.backup-*/` directories (which could contain nested `.opencode/node_modules` — tens of thousands of files), and `collectAllFiles` combined recursion with `files.push(...largeArray)` spread. Rewritten as iterative stack traversal. Exclude dirs (`node_modules`, `.backup-*`, etc.) are now skipped at scan time instead of copy time. Symlinks and Windows NTFS junctions are skipped to avoid cyclic scans. `BACKUP_EXCLUDE_PATTERNS` matching normalizes backslashes to forward slashes so Windows paths like `.claude\\worktrees\\...` match. `DEBUG=1` / `TRELLIS_DEBUG=1` env now prints full stack traces for easier triage. See `update.ts:683-790`, `cli/index.ts:130`.\n\n**Release tooling:**\n- feat(release): new `packages/cli/scripts/check-manifest-continuity.js` — pre-release gate that queries npm for published versions and fails non-zero if any lacks a local manifest. Hooked into `release` / `release:minor` / `release:major` / `release:beta` / `release:rc` / `release:promote` before `pnpm test`. Historical gaps (0.1.x pre-manifest era, 0.2.1–0.2.11 old monolith, 0.3.10-beta.0 first public prerelease) whitelisted in `KNOWN_GAPS`; the list documents that it should not be extended.\n- feat(create-manifest): `create-manifest.js` now refuses to (re)write a manifest whose version is already on npm — even with `force: true`. Interactive mode also checks npm before the existing local-file overwrite prompt.\n- fix(migrations): restored `packages/cli/src/migrations/manifests/0.5.0-beta.10.json`. Reconstructed from the actual tarball content (three bug fixes + migrationGuide back-fills + docs-site changelog pre-release gate), not the earlier Qoder-split draft that was consolidated into beta.9 before publish. `KNOWN_GAPS` shrinks from 22 to 21.\n\n**Test fixes:**\n- fix(test): `update.integration.test.ts` and `init-joiner.integration.test.ts` `vi.mock(\"node:child_process\")` now conditionally returns `\"Python 3.11.12\"` on `python3 --version` calls instead of blanket `\"\"`. Resolves 36 pre-existing failures caused by `requireSupportedPython` throwing `Python command not found` in vitest child processes. Full suite now 664/664 green.\n- test(update): regression coverage for the backup-phase crash added in `test/commands/update-internals.test.ts` and `test/commands/update.integration.test.ts`.",
  "migrations": [],
  "notes": "**Existing tasks**: keep working. Consumers (hook, prelude, validate, list-context) all skip rows without a `file` key, so old `_example` seed rows are naturally ignored. If your existing `implement.jsonl` / `check.jsonl` were generated by 0.5.0-beta.11-and-earlier `init-context` and point at paths that don't exist in your monorepo spec layout (typical when `package = backend | frontend` instead of `package = business-domain`), re-curate per workflow.md Phase 1.3 — or leave them alone and the sub-agent falls back to prd.md + stderr warning.\n\n**AI instructions (for an agent helping a user through this change)**:\n\n1. Do NOT run `task.py init-context` — it's gone. If you see the deprecation error (exit 2), read `.trellis/workflow.md` Phase 1.3 and curate jsonl directly.\n2. When creating a new task, `task.py create` already seeds empty-but-valid jsonl on sub-agent platforms. Your Phase 1.3 job: open `implement.jsonl` / `check.jsonl`, replace the `_example` line with real `{\"file\": ..., \"reason\": ...}` entries pointing at `.trellis/spec/**/*.md` and `{TASK_DIR}/research/**/*.md` that apply to the task. Never list code files — those are read during Phase 2 implement, not pre-registered.\n3. Run `python3 ./.trellis/scripts/get_context.py --mode packages` to discover which spec layers are available in the current project.\n4. If the session-start breadcrumb shows `Status: PLANNING (Phase 1.3)` right after task.py create, that is correct — it means curation hasn't happened yet. Proceed with Phase 1.3 per workflow.md. The READY status only appears after at least one curated entry is written.\n5. If a user's old task was created under 0.5.0-beta.11 with `init-context` output pointing at `.trellis/spec/<pkg>/backend/index.md` and those paths don't exist on their monorepo, don't try to 'fix' the old script — re-curate the jsonl to the paths that actually exist. Use the `add-context` command or edit the file directly.\n\n**Workaround for users still on a pre-beta.12 published CLI who hit the `Maximum call stack size exceeded` crash during `trellis update`**: `rm -rf .trellis/.backup-*` drops the nested-node_modules source of the overflow, then re-run `trellis update` (still on the old CLI) to complete the upgrade, OR upgrade to beta.12 first via `npm i -g @mindfoldhq/trellis@0.5.0-beta.12` and run update from there."
}
