diff --git a/TODO.md b/TODO.md index 43c00f7..29392b0 100644 --- a/TODO.md +++ b/TODO.md @@ -9,6 +9,13 @@ ## Backlog tickets +- [ ] [`ticket-060`](project/ticket-060/README.md) — replace the stale current + version literal in the documentation extraction test. Current state: + `IN_PROGRESS / VALIDATION`; coordinated by ticket-058. +- [ ] [`ticket-058`](project/ticket-058/README.md) — synchronize release, + runtime, SDK and generated-provenance version identity and add a deterministic + drift gate. Plan and owner-ticket creation are approved; current state: + `BLOCKED / WAIT_FOR_DEPENDENCIES` while ticket-054 reserves `integration`. - [ ] [`ticket-051`](project/ticket-051/README.md) — wire `scripts/github-event-log.mjs` into CI with explicit flags only. Current state: `PLAN / WAIT_FOR_APPROVAL`; ticket-048 is now merged. diff --git a/project/TICKETS.md b/project/TICKETS.md index f5e2b87..4d180c2 100644 --- a/project/TICKETS.md +++ b/project/TICKETS.md @@ -50,4 +50,6 @@ of `project/README.md`, which remains a generated technical-analysis artifact. | **ticket-054** | [`README.md`](./ticket-054/README.md) | [`preprompt.md`](./ticket-054/preprompt.md) | - | [`ai-codex.md`](./ticket-054/ai-codex.md) | [`ai-codex-logs.txt`](./ticket-054/ai-codex-logs.txt) | [`changelog.md`](./ticket-054/changelog.md) | | **ticket-055** | [`README.md`](./ticket-055/README.md) | [`preprompt.md`](./ticket-055/preprompt.md) | - | [`ai-codex.md`](./ticket-055/ai-codex.md) | [`ai-codex-logs.txt`](./ticket-055/ai-codex-logs.txt) | [`changelog.md`](./ticket-055/changelog.md) | | **ticket-056** | [`README.md`](./ticket-056/README.md) | [`preprompt.md`](./ticket-056/preprompt.md) | - | [`ai-codex.md`](./ticket-056/ai-codex.md) | [`ai-codex-logs.txt`](./ticket-056/ai-codex-logs.txt) | [`changelog.md`](./ticket-056/changelog.md) | +| **ticket-058** | [`README.md`](./ticket-058/README.md) | [`preprompt.md`](./ticket-058/preprompt.md) | - | [`ai-codex.md`](./ticket-058/ai-codex.md) | [`ai-codex-logs.txt`](./ticket-058/ai-codex-logs.txt) | [`changelog.md`](./ticket-058/changelog.md) | +| **ticket-060** | [`README.md`](./ticket-060/README.md) | [`preprompt.md`](./ticket-060/preprompt.md) | - | [`ai-codex.md`](./ticket-060/ai-codex.md) | [`ai-codex-logs.txt`](./ticket-060/ai-codex-logs.txt) | [`changelog.md`](./ticket-060/changelog.md) | diff --git a/project/ticket-058/README.md b/project/ticket-058/README.md new file mode 100644 index 0000000..517bf6e --- /dev/null +++ b/project/ticket-058/README.md @@ -0,0 +1,90 @@ +# Ticket 058: Synchronize todo2code release and runtime version identity + +- **ID**: ticket-058 +- **Owner**: unresolved:human +- **Status**: BLOCKED +- **Workflow state**: WAIT_FOR_DEPENDENCIES +- **Created**: 2026-08-08 + +## Goal and scope + +Restore one auditable todo2code release identity across the root release +metadata, SDK manifests, CLI output and every generated DSL provenance +envelope. Add a dependency-free integration gate that fails closed when a +future release updates only part of that identity. + +This ticket is the integration coordinator. Paths owned by `core-dsl`, +`extractors` and `runtime` must be corrected through separate governed tickets +that point back to ticket-058; this ticket does not transfer their ownership. + +## Verified regression + +At `main@738d7be93168fe73cccf14d3d589e545919c9a6f`: + +```text +package.json 0.5.1 +VERSION 0.5.1 +pyproject.toml 0.5.1 +Python/Rust/TypeScript SDKs 0.5.1 +src/core/version.ts 0.5.0 +t2c --version todo2code 0.5.0 +doDSL DevelopmentEvidenceDSL producerVersion 0.5.0 +``` + +Commit `99286994cc604e80b401fc16f4230e33e90df253` raised the release and +SDK metadata to `0.5.1` without changing the runtime constant. Several tests +then encoded `0.5.0` directly, so the normal suite preserved rather than +detected the drift. + +## Proposed delivery + +1. Add an integration-owned, dependency-free version-contract verifier and + focused tests under `scripts/`, then make it part of `npm run verify`. +2. Through a `core-dsl` ticket, align `T2C_VERSION` with the accepted release + identity. +3. Through `extractors` and `runtime` tickets, replace current-version literals + with the exported runtime identity where they assert current behavior. + Historical fixtures remain pinned when their old version is evidence. +4. Re-run the complete host, governance and Docker validation. +5. Rebuild the pinned todo2code runtime used by doDSL and prove that a new + DevelopmentEvidenceDSL bundle reports `producerVersion "0.5.1"` while + retaining its exact Git commit/tree and no authority or mutation effect. + +Ticket creation with `--force-new` was explicitly authorized by the human on +2026-08-08. That authorization permits this concurrent planning ticket; it is +not approval to edit implementation paths or weaken the active ticket limits. + +## Acceptance criteria + +- [x] AC-01: A human approves this scope and the multi-workstream split. +- [ ] AC-02: Root release metadata, SDK manifests, `T2C_VERSION`, CLI output + and newly generated provenance all report the same accepted version. +- [ ] AC-03: A dependency-free verifier emits a stable diagnostic and non-zero + status for every supported version-identity mismatch. +- [ ] AC-04: Tests asserting the current runtime use the canonical exported + identity; deliberately historical fixtures remain visibly pinned. +- [ ] AC-05: `npm run verify`, governance, Docker smoke and both Docker E2E + profiles pass without skipped checks being counted as passes. +- [ ] AC-06: A fresh doDSL compile records todo2code `0.5.1`, an exact source + revision/tree and `AUTHORITY_EFFECT none` / `MUTATION_EFFECT none`. + +## Participants + +- Human participant: unresolved; no `user-*` file was created. +- Agent participant: [ai-codex.md](ai-codex.md). + +## Approval gate + +The human approved this plan and creation of the owner-workstream tickets on +2026-08-08. This ticket is now `BLOCKED / WAIT_FOR_DEPENDENCIES`: ticket-054 +still reserves `integration`, so the verifier and root verify-hook cannot enter +`EDIT`. Distinct child workstreams may proceed only through their own approved +tickets. Conversation approval is an audit note, not trusted merge authority. + +## Non-goals + +- No new release number, Git tag or package publication. +- No dependency, secret, AQL, Docker runtime or model configuration change. +- No reinterpretation of historical `0.5.0` fixtures as current evidence. +- No command execution or mutation authority derived from LLM output. +- No direct edit of paths owned by another workstream under ticket-058. diff --git a/project/ticket-058/ai-codex-logs.txt b/project/ticket-058/ai-codex-logs.txt new file mode 100644 index 0000000..c2c075f --- /dev/null +++ b/project/ticket-058/ai-codex-logs.txt @@ -0,0 +1,39 @@ +2026-08-08 pre-implementation audit + +PASS repository state + main@738d7be93168fe73cccf14d3d589e545919c9a6f + original worktree clean before ticket allocation + +FAIL release identity consistency + package.json=0.5.1 + VERSION=0.5.1 + pyproject.toml=0.5.1 + sdk/python=0.5.1 + sdk/rust=0.5.1 + sdk/typescript=0.5.1 + src/core/version.ts=0.5.0 + dist CLI output=todo2code 0.5.0 + +EVIDENCE root cause + commit 99286994cc604e80b401fc16f4230e33e90df253 updated release and SDK + metadata from 0.5.0 to 0.5.1 but did not update src/core/version.ts + +EVIDENCE downstream observation + doDSL project dodsl-smoke reports producer=todo2code, producerVersion=0.5.0 + evidence URI=urn:onlydsl:development-evidence:sha256:7c65453adebf716a4e08aab09ed8f107e551f93232c011a61dfe5b47a55491ac + authorityEffect=none, mutationEffect=none + +AUTHORIZATION + Human explicitly approved creation of a concurrent integration ticket with + --force-new. Implementation approval has not been granted. + +No implementation path changed. State: WAIT_FOR_APPROVAL. + +PASS ./project/governance-check.sh + GOV-PASS: passed (0 errors, 0 warnings) + +2026-08-08 human plan decision + APPROVED ticket-058 plan + APPROVED creation of owner-workstream tickets + NOT trusted merge authorization + ticket-058 remains non-active while ticket-054 reserves integration diff --git a/project/ticket-058/ai-codex.md b/project/ticket-058/ai-codex.md new file mode 100644 index 0000000..b54431d --- /dev/null +++ b/project/ticket-058/ai-codex.md @@ -0,0 +1,51 @@ +--- +participant-id: agent:codex +participant: codex +role: agent +ticket: ticket-058 +--- +# Participant: codex (AI agent) + +## Understanding + +Todo2code currently has two simultaneously true but incompatible identities. +Release and SDK metadata say `0.5.1`, while the runtime constant, CLI and every +new provenance envelope say `0.5.0`. doDSL is not inventing the older value; +it reads it from the pinned todo2code CLI and binds it to the exact analysed Git +commit and tree. + +Changing one string would make the immediate output look correct but would not +prevent the next partial release. The repair therefore needs a deterministic +version contract plus removal of current-version literals from behavioral +tests. Historical artifacts must not be rewritten. + +## Execution plan after approval + +1. Create separate `core-dsl`, `extractors` and `runtime` tickets with + ticket-058 as their integration coordinator. +2. Align the core runtime version and replace only current-behavior literals in + the owning test workstreams. +3. Once the active integration reservation permits it, add the no-dependency + version verifier, focused negative fixtures and the root verify hook. +4. Run focused tests, `npm run verify`, governance, Docker smoke and both E2E + profiles. +5. Rebuild the todo2code image consumed by doDSL, compile a fresh candidate and + verify the resulting DevelopmentEvidenceDSL identity and safety fields. + +## Actual changes + +- Audited all release/runtime declarations at exact main HEAD. +- Identified the release commit that introduced the mismatch. +- Confirmed the live CLI emits `todo2code 0.5.0` while package and VERSION are + `0.5.1`. +- Confirmed doDSL faithfully persists that emitted producer version. +- Created planning evidence only; no implementation file changed. +- Recorded the human approval of this plan and authorization to create the + three owner-workstream tickets. + +## Blockers + +- Ticket-054 currently reserves the `integration` workstream. The approved + `--force-new` exception created this ticket but does not silently + override active-scope enforcement. +- Each non-integration path requires its owning workstream ticket. diff --git a/project/ticket-058/changelog.md b/project/ticket-058/changelog.md new file mode 100644 index 0000000..b880580 --- /dev/null +++ b/project/ticket-058/changelog.md @@ -0,0 +1,14 @@ +# Ticket Changelog (ticket-058) + +## [0.1.0] - 2026-08-08 + +- Created the explicitly authorized concurrent integration planning ticket. +- Recorded the exact `0.5.1` release metadata versus `0.5.0` runtime mismatch. +- Defined a multi-workstream repair with a dependency-free drift gate. +- Preserved the distinction between current-version assertions and historical + fixtures. +- Made no executable, runtime, dependency, Docker or consumer changes. +- Passed the repository governance check with zero errors and zero warnings. +- Recorded human approval of the plan and owner-ticket creation. +- Moved to `BLOCKED / WAIT_FOR_DEPENDENCIES` until ticket-054 releases the + integration workstream. diff --git a/project/ticket-058/intent.json b/project/ticket-058/intent.json new file mode 100644 index 0000000..eed31bf --- /dev/null +++ b/project/ticket-058/intent.json @@ -0,0 +1,105 @@ +{ + "schema": "new-project.intent/v3", + "ticket": "ticket-058", + "summary": "Synchronize todo2code release and runtime version identity", + "workstream": "integration", + "classification": { + "kind": "BUG", + "priority": "P1", + "origin": "regression" + }, + "allowedPaths": [ + "project/ticket-058/**", + "TODO.md", + "project/TICKETS.md", + "package.json", + "scripts/verify-version-contract.mjs", + "scripts/verify-version-contract.test.mjs" + ], + "forbiddenPaths": [ + "project/ticket-*/user-*.md", + "src/**", + "test/**", + "sdk/**", + "Dockerfile*", + "compose*.yml", + ".env*" + ], + "stacks": ["node", "docker"], + "dependsOn": [], + "conflictsWith": ["ticket-054"], + "integrationTicket": null, + "delivery": { + "acceptedBaseSha": "738d7be93168fe73cccf14d3d589e545919c9a6f", + "targetBranch": "main", + "outcome": "Every current todo2code artifact exposes one release identity and a deterministic integration gate prevents partial future bumps", + "nonGoals": [ + "No new version, tag or publication", + "No dependency or runtime toolchain change", + "No rewrite of historical versioned evidence", + "No authority or command execution from model output" + ], + "complexity": "S", + "estimatedMinutes": 25, + "budgets": { + "maxImplementationFiles": 3, + "maxAffectedComponents": 2, + "maxPublicInterfaceChanges": 0, + "maxRuntimeDependencies": 0 + }, + "architecture": { + "status": "accepted", + "decision": "Treat release version as an integration contract, verify every declaration deterministically and let each workstream update only its owned current-version assertions", + "components": [ + { + "name": "version-contract-verifier", + "paths": [ + "scripts/verify-version-contract.mjs", + "scripts/verify-version-contract.test.mjs" + ] + }, + { + "name": "root-verification-orchestration", + "paths": ["package.json"] + } + ], + "responsibilityChanges": false, + "interfaceChanges": [], + "dataChanges": [ + "Current generated provenance changes from the stale runtime identity 0.5.0 to the accepted release identity 0.5.1" + ], + "ui": {"impact": "none", "states": [], "evidence": []}, + "rollback": "Remove the verifier hook and scripts; workstream-owned version corrections retain their own rollback and evidence" + }, + "runtimeDependencies": [], + "validation": [ + { + "criterion": "AC-03", + "commands": [ + "node --test scripts/verify-version-contract.test.mjs", + "node scripts/verify-version-contract.mjs" + ], + "evidence": "The verifier accepts one identity and fails each isolated mismatch with a stable diagnostic" + }, + { + "criterion": "AC-05", + "commands": [ + "npm run verify", + "./project/governance-check.sh", + "make docker-smoke", + "make e2e-core", + "make e2e-full" + ], + "evidence": "Host, policy and both Docker profiles pass without hidden fallback" + }, + { + "criterion": "AC-06", + "commands": [ + "doDSL compile with requireTodo2code=true", + "onlyDSL DevelopmentEvidenceDSL verification" + ], + "evidence": "A fresh immutable evidence bundle reports todo2code 0.5.1 and no authority or mutation effect" + } + ] + } +} diff --git a/project/ticket-058/preprompt.md b/project/ticket-058/preprompt.md new file mode 100644 index 0000000..78e20a4 --- /dev/null +++ b/project/ticket-058/preprompt.md @@ -0,0 +1,10 @@ +# Ticket preprompt + +- **Task ID**: ticket-058 +- **Task title**: Synchronize todo2code release and runtime version identity +- **Created**: 2026-08-08T21:46:52Z + +The human explicitly authorized creating this concurrent `integration` ticket +with `--force-new`. The approval applies to ticket creation, not implementation. +Keep executable implementation outside this governance/evidence directory and +respect every workstream's owned paths. diff --git a/project/ticket-060/README.md b/project/ticket-060/README.md new file mode 100644 index 0000000..fcddad9 --- /dev/null +++ b/project/ticket-060/README.md @@ -0,0 +1,37 @@ +# Ticket 060: Use canonical runtime version in documentation extraction test + +- **ID**: ticket-060 +- **Owner**: unresolved:human +- **Status**: IN_PROGRESS +- **Workflow state**: VALIDATION +- **Created**: 2026-08-08 + +## Goal and scope + +Replace the literal `0.5.0` in the current documentation-extraction behavior +test with the exported `T2C_VERSION`. The test will continue proving runtime +provenance while no longer preserving a stale release identity. + +## Acceptance criteria + +- [x] AC-01: A human approves the one-test-file scope. +- [x] AC-02: `test/docs.test.ts` asserts current provenance through + `T2C_VERSION`, not a copied version string. +- [ ] AC-03: Documentation extraction tests pass with ticket-059's runtime + correction and no historical fixture is changed. + +## Participants + +- Human participant: unresolved; no `user-*` file was created. +- Agent participant: [ai-codex.md](ai-codex.md). + +## Approval gate + +The human approved tickets 059–063 and transition to `EDIT` after dependencies +on 2026-08-09. Ticket-058 remains the integration coordinator, not an +unfinished implementation prerequisite. + +## Non-goals + +- No extractor behavior, source, fixture, dependency or Docker change. +- No replacement of historical version evidence. diff --git a/project/ticket-060/ai-codex-logs.txt b/project/ticket-060/ai-codex-logs.txt new file mode 100644 index 0000000..4e84732 --- /dev/null +++ b/project/ticket-060/ai-codex-logs.txt @@ -0,0 +1,25 @@ +2026-08-08 pre-implementation evidence + +FAIL test/docs.test.ts + current metadata.generation.runtimeVersion assertion copies literal 0.5.0 + +SCOPE + test/docs.test.ts only + +No implementation changed. State: WAIT_FOR_APPROVAL. + +PASS ./project/governance-check.sh + GOV-PASS: passed (0 errors, 0 warnings) + +2026-08-09 approval + APPROVED ticket-060 plan and transition to EDIT + ticket-058 retained as integrationTicket, not dependsOn + +2026-08-09 implementation validation + PASS npm ci (3 packages, 0 vulnerabilities) + PASS npm run build + PASS node --test dist/test/docs.test.js (5/5) + PASS ./project/governance-check.sh (0 errors, 0 warnings) + +Implementation scope + test/docs.test.ts: current runtime assertion now uses T2C_VERSION diff --git a/project/ticket-060/ai-codex.md b/project/ticket-060/ai-codex.md new file mode 100644 index 0000000..555ff68 --- /dev/null +++ b/project/ticket-060/ai-codex.md @@ -0,0 +1,32 @@ +--- +participant-id: agent:codex +participant: codex +role: agent +ticket: ticket-060 +--- +# Participant: codex (AI agent) + +## Understanding + +The deterministic documentation test asserts a current generated provenance +value but copied `0.5.0` directly. That made the suite encode the regression. + +## Execution plan + +1. Wait for explicit approval and enter `IN_PROGRESS / EDIT`. +2. Import `T2C_VERSION` in `test/docs.test.ts` and use it in the one current + runtime assertion. +3. Build and run the focused documentation tests. +4. Provide the commit to ticket-058 for combined validation. + +## Actual changes + +- Classified the literal as a current assertion, not historical evidence. +- Human approved the exact scope and transition to `EDIT` on 2026-08-09. +- Imported `T2C_VERSION` and replaced the one current-version literal. +- Build, all five documentation tests and governance pass. + +## Blockers + +- No blocker remains inside this workstream; integrated validation is owned by + ticket-058. diff --git a/project/ticket-060/changelog.md b/project/ticket-060/changelog.md new file mode 100644 index 0000000..865e7eb --- /dev/null +++ b/project/ticket-060/changelog.md @@ -0,0 +1,12 @@ +# Ticket Changelog (ticket-060) + +## [0.1.0] - 2026-08-08 + +- Created the extractor-owned child ticket coordinated by ticket-058. +- Classified the stale literal as a current-behavior assertion. +- Made no test change before approval. +- Passed governance with zero errors and zero warnings. +- Recorded human approval and transition to `IN_PROGRESS / EDIT`. +- Corrected ticket-058 to the dedicated integration relationship. +- Replaced the documentation test's stale current-version literal with + `T2C_VERSION`; five focused tests pass. diff --git a/project/ticket-060/intent.json b/project/ticket-060/intent.json new file mode 100644 index 0000000..e655ce2 --- /dev/null +++ b/project/ticket-060/intent.json @@ -0,0 +1,50 @@ +{ + "schema": "new-project.intent/v3", + "ticket": "ticket-060", + "summary": "Use canonical runtime version in documentation extraction test", + "workstream": "extractors", + "classification": {"kind": "BUG", "priority": "P1", "origin": "regression"}, + "allowedPaths": [ + "project/ticket-060/**", + "TODO.md", + "project/TICKETS.md", + "test/docs.test.ts" + ], + "forbiddenPaths": [ + "project/ticket-*/user-*.md", + "src/**", + "package.json", + "package-lock.json", + "sdk/**", + "Dockerfile*", + "compose*.yml", + ".env*" + ], + "stacks": ["node", "docker"], + "dependsOn": [], + "conflictsWith": [], + "integrationTicket": "ticket-058", + "delivery": { + "acceptedBaseSha": "132f87963921cd49dafa19b643b0528a3a434dd0", + "targetBranch": "main", + "outcome": "Documentation extraction tests follow the canonical runtime identity instead of preserving a stale literal", + "nonGoals": ["No extractor behavior change", "No historical fixture rewrite", "No dependency or Docker change"], + "complexity": "XS", + "estimatedMinutes": 10, + "budgets": {"maxImplementationFiles": 1, "maxAffectedComponents": 1, "maxPublicInterfaceChanges": 0, "maxRuntimeDependencies": 0}, + "architecture": { + "status": "accepted", + "decision": "Reference the exported runtime identity in the current-behavior assertion", + "components": [{"name": "documentation-extraction-test", "paths": ["test/docs.test.ts"]}], + "responsibilityChanges": false, + "interfaceChanges": [], + "dataChanges": [], + "ui": {"impact": "none", "states": [], "evidence": []}, + "rollback": "Restore the literal only if the test is deliberately converted into a versioned historical fixture" + }, + "runtimeDependencies": [], + "validation": [ + {"criterion": "AC-03", "commands": ["npm run build", "node --test dist/test/docs.test.js"], "evidence": "Focused documentation extraction tests pass with canonical runtime identity"} + ] + } +} diff --git a/project/ticket-060/preprompt.md b/project/ticket-060/preprompt.md new file mode 100644 index 0000000..2374a66 --- /dev/null +++ b/project/ticket-060/preprompt.md @@ -0,0 +1,7 @@ +# Ticket preprompt + +- **Task ID**: ticket-060 +- **Task title**: Use canonical runtime version in documentation extraction test +- **Created**: 2026-08-08 + +Change only the extractor-owned current-behavior assertion after approval. diff --git a/test/docs.test.ts b/test/docs.test.ts index 3a49759..58e8fc1 100644 --- a/test/docs.test.ts +++ b/test/docs.test.ts @@ -4,6 +4,7 @@ import os from 'node:os'; import path from 'node:path'; import test from 'node:test'; import { extractDocumentationBaseline } from '../src/extractors/docs-deterministic.js'; +import { T2C_VERSION } from '../src/version.js'; import { makeConfig } from './helpers.js'; test('deterministic documentation baseline records headings, code blocks and explicit references', async () => { @@ -32,7 +33,7 @@ test('deterministic documentation baseline records headings, code blocks and exp assert.ok(result.records.every((record) => record.source.kind === 'document')); assert.ok(result.records.every((record) => record.source.extractor === 't2c/markdown-documentation@2')); assert.ok(result.records.every((record) => record.metadata.generation.generator === 't2c/markdown-documentation')); - assert.ok(result.records.every((record) => record.metadata.generation.runtimeVersion === '0.5.0')); + assert.ok(result.records.every((record) => record.metadata.generation.runtimeVersion === T2C_VERSION)); const reference = result.records[1]; assert.deepEqual(reference?.statement.target.paths, ['src/runtime.ts']); assert.deepEqual(reference?.statement.target.symbols, ['validateContract']);