Skip to content

release: v0.2.4#149

Merged
fedorovvvv merged 7 commits into
mainfrom
release/v0.2.4
May 25, 2026
Merged

release: v0.2.4#149
fedorovvvv merged 7 commits into
mainfrom
release/v0.2.4

Conversation

@fedorovvvv
Copy link
Copy Markdown
Collaborator

Summary

Patch release v0.2.4 — graph layout normalization.

  • ForceView no longer drifts between renders (mulberry32-seeded init).
  • All 5 views sort nodes by connection degree as a secondary key.
  • Sankey / Sunburst untouched (already deterministic).

Changes since v0.2.3

Test plan

Refs: PRD-033, RFC-027, EVID-039

fedorovvvv and others added 6 commits May 9, 2026 21:52
## Summary
Back-merge of `release/v0.2.3` into `develop` per Git Flow §2.5 step 10.

Brings version bump `0.2.3` from `package.json` +
`template/package.json` into develop so future releases start from the
correct baseline.

## Test plan
- [ ] Only version bump in diff (no feature changes)
- [ ] CI green

🤖 Generated with [Claude Code](https://claude.com/claude-code)
…first sort

Replaces non-deterministic Math.random() initialization in ForceView with
mulberry32-seeded jitter keyed on nodeId, so the same dataset always renders
to the same starting configuration. Adds a shared degreeRank comparator
(byDegreeDesc) and threads it through ForceView (pre-sort before d3-force),
RadialView (pre-sort ring members before angular layout), TreeView, MatrixView,
and LanesView (secondary sort key after kind / status), so high-degree
artifacts surface earlier within their semantic group.

New lib: seeded-rand.ts (FNV-1a + mulberry32 + seededJitter) and degree.ts
(buildDegreeMap + byDegreeDesc). New tests: seeded-rand.test.ts and
degree-order.test.ts. 87/87 vitest pass; svelte-check 0 errors; smoke ALL
IMAGES PASS.

Sankey/Sunburst views are already deterministic and intentionally untouched.

Refs: PRD-033, RFC-027, EVID-039
Activation gate (rule 11) before merge — R_eff=1.00 grade A on all three.

Refs: PRD-033, RFC-027, EVID-039
…first sort (#148)

## Summary

- ForceView no longer drifts between renders: `Math.random()` replaced
with mulberry32 PRNG keyed on `nodeId` (FNV-1a 32-bit hash). Same
dataset always renders to the same starting configuration.
- One shared `degreeRank` comparator (`byDegreeDesc`) threaded through 5
views — high-degree artifacts surface earlier within their semantic
group.
- 87/87 vitest pass, svelte-check 0 errors / 0 warnings (1076 files),
`node scripts/smoke.mjs` exits 0 (ALL IMAGES PASS).

## Why

User-visible chaos in `/` viewer: every re-mount of ForceView produced a
different layout for the same data, and static views (Tree / Matrix /
Lanes / Radial) ordered nodes purely by kind + id with zero awareness of
connection density. High-impact PRDs were buried alphabetically
alongside zero-edge stubs. See PRD-033 §Problem.

## What changed

**New lib** (under `template/src/widgets/dependency-graph/lib/`):
- `seeded-rand.ts` — `hashStringFnv1a`, `mulberry32`, `seededJitter`
- `degree.ts` — `DegreeMap`, `buildDegreeMap` (skip self-edges),
`byDegreeDesc<T>(map, tieBreak?)`
- `seeded-rand.test.ts` — 4 tests (determinism, hash inequality, jitter
stability + bounds + per-id distinctness)
- `degree-order.test.ts` — 5 tests (counts, self-edge exclusion,
ordering invariant, default tie-break, custom tie-break)

**Modified views**:
- `ForceView.svelte` — `seededJitter` replaces `Math.random()`; nodes
pre-sorted by degree before d3-force
- `RadialView.svelte` — ring `ids` pre-sorted by degree before angular
layout
- `TreeView.svelte`, `MatrixView.svelte`, `LanesView.svelte` — degree as
secondary sort key (after kind / status, before id)

`SankeyView` and `SunburstView` are intentionally untouched — already
deterministic.

## Test plan

- [x] `cd template && npx vitest run src/widgets/dependency-graph/lib/`
— PASS (87) FAIL (0)
- [x] `npm run build` from repo root — exit 0, svelte-check 0 errors
- [x] `node scripts/smoke.mjs` from repo root — ALL IMAGES PASS, exit 0
- [x] `grep -rn 'Math.random' template/src/widgets/dependency-graph/` —
no matches
- [ ] CI matrix (ubuntu / macos / windows × Node 22) — runs on PR
- [ ] Visual smoke against `npm run dev:playground` (123-artifact seeded
workspace) — recommended before merge

Refs: PRD-033, RFC-027, EVID-039
@fedorovvvv fedorovvvv enabled auto-merge May 25, 2026 18:23
@fedorovvvv fedorovvvv merged commit 03f6457 into main May 25, 2026
5 of 6 checks passed
@fedorovvvv fedorovvvv deleted the release/v0.2.4 branch May 25, 2026 18:39
fedorovvvv added a commit that referenced this pull request May 25, 2026
## Summary

Back-merge of v0.2.4 from `main` into `develop` — propagates the `0.2.4`
version bump so subsequent feature branches start at the published SHA.

Branch `release/v0.2.4` was auto-deleted after merging PR #149; this
branch was created off `main` to perform the same back-merge per
[`CLAUDE.md` Release procedure §10](../blob/develop/CLAUDE.md).

## Why

Standard final step of the release flow.

## Notes

- `v0.2.4` tag pushed on `main` ✅
- GitHub Release v0.2.4 published ✅
- `release.yml` ran but `npm publish` returned **404 PUT
@forgeplan/web** — likely `NPM_TOKEN` repo secret needs rotation. Tag is
intact; can rerun the workflow after the secret is refreshed, or publish
manually. NOT a blocker for this PR.

Refs: PRD-033, RFC-027, EVID-039
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant