contract-driven-delivery 2.0.9 → 2.0.10

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 (3) hide show
  1. package/CHANGELOG.md +49 -0
  2. package/dist/cli/index.js +1617 -1564
  3. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,54 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.0.10] - 2026-05-04
4
+
5
+ Two more context-scan determinism bugs, both surfaced verifying the 2.0.9
6
+ fix on the same consumer repo.
7
+
8
+ ### Fixed
9
+
10
+ - **`inputs-digest` is now portable across clones**: previously the digest
11
+ was computed from `<absolute-path>:<content-sha>`, so the value depended
12
+ on `cwd`. A user's local repo at `D:\TODO\` and a fresh CI clone at
13
+ `/runner/work/TODO/` would always produce different digests for the
14
+ same content, causing `cdd-kit doctor` to report "inputs changed"
15
+ permanently after every fresh clone. Now uses repo-relative path —
16
+ digest depends only on the file's logical location and content.
17
+ Applied identically to `src/commands/context-scan.ts`,
18
+ `src/commands/doctor.ts`, and `src/commands/new-change.ts`.
19
+ - **Nested build outputs (`dist/`, `build/`, `out/`) excluded at any depth**:
20
+ `FORBIDDEN_DIRECTORY_NAMES` now lists these as basename matches, so
21
+ `frontend/dist/`, `apps/web/build/`, `packages/lib/out/` get pruned
22
+ from the project-map tree. Previously only top-level `dist/` and
23
+ `build/` were caught.
24
+
25
+ - **Hash-based code-map freshness**: previously `cdd-kit gate` and
26
+ `cdd-kit doctor` used file mtime to decide whether the code-map was
27
+ fresh. mtime is unreliable across `git clone` (clone resets mtimes in
28
+ unpredictable order), so any fresh clone reported `code-map stale: N
29
+ files` even when content was bit-identical — and `cdd-kit gate` treats
30
+ that as a hard error.
31
+
32
+ Fix: code-map.yml now embeds `# sources-digest: <sha256>` in its header
33
+ (covers all input file paths + content). Freshness check first does
34
+ the fast mtime check; when mtime says stale, falls back to verifying
35
+ the digest. Real content changes are still detected; mtime-only drift
36
+ is silently overridden. Maps generated by cdd-kit < 2.0.10 lack the
37
+ digest line; for those, the legacy mtime verdict is used.
38
+
39
+ ### Migration
40
+
41
+ After upgrading, re-run `cdd-kit context-scan` once and commit the new
42
+ `specs/context/*.md`. Same for `cdd-kit code-map` — the new map will
43
+ include the `# sources-digest:` line that gate/doctor use for portable
44
+ freshness.
45
+
46
+ The new `inputs-digest` and `sources-digest` are in different formats
47
+ than 2.0.9 (repo-relative paths, content-keyed) so existing maps will
48
+ look stale until regenerated. This is one-time. From then on, fresh
49
+ clones and CI will produce stable digests that match the committed
50
+ values, eliminating false-positive doctor warnings.
51
+
3
52
  ## [2.0.9] - 2026-05-04
4
53
 
5
54
  Bug-fix patch. Discovered when verifying a real consumer repo (TODOLIST)