Commit Graph
4 Commits
Author SHA1 Message Date
byrongamatosandClaude Sonnet 4.6 a6efd4ee5e refactor(h3d-carve-17): cut-17 — alias removal + stale doc comment cleanup
Cleanups:
- scene-init.js: remove dead DI alias getHighwayCanvas:_getHighwayCanvasAlias (Creed note)
  setHighwayCanvas now correctly gains its own line in the DI block
- note-renderer.js: two stale line-number refs → module-relative refs (Toby r4 LOW)
- arp.js: stale 'at line 4025' doc comment → 'factory-scope fn in screen.js'

Gates:
- ESLint: 0 errors on scene-init.js
- plugin.json: 3.52.0 → 3.53.0
- Tests: 448/448 (alias kill test added; DI count repinned 178→179; version test updated)
  Note: DI count is 179 post-edit (setHighwayCanvas promoted to line-first position)

CAF sweep: waived (no setter-arg changes in scope)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014uZ169yfoFYArXz962g7KW
2026-09-06 07:57:08 +02:00
byrongamatosandClaude Sonnet 4.6 6c15ed9dda fix(h3d-carve-16): Toby r1 — F1 ternary, F2 dead DI, F3 naming guard, F4 smoke honesty
F1 (HIGH): Fix truncated-ternary in _bgLoadSettings — setZoomSmoothing and
setTiltSmoothing were closing before the ternary, storing the boolean
_bgHasStored(...) result instead of the camera-smoothing value. Move
closing ) to after : _cameraSmoothing. Add kill tests for both setters
asserting the argument contains '?'.

F2 (MED): Remove 13 dead DI params (5 lines) from createSceneInit signature
and matching entries from screen.js wiring:
  - FRET_WIRE_HIT_OP / HIT_INTENSITY / HIT_DECAY (renderer.js only)
  - updateStringHighlights (declared null, never called)
  - getIsDestroyed (screen.js lifecycle flag, not scene-init's concern)
  - setChartEnv/PrevT, setBcBeatIdx/NoteIdx/ChordIdx (BC chart-sync: per-frame)
  - setTintR/G/B (BC tint: per-frame, managed outside scene-init)
DI count repinned: 183 → 178.

F3 (LOW): Add naming-correspondence guard — for every getX in the DI,
assert a matching setX exists unless getX is in READ_ONLY (6 pinned
stable-ref getters that scene-init never writes).

F4 (honesty): Rename smoke test — was 'setters called before null-T throw'
(wrong: null canvas returns before T is accessed, no setter is called).
Now: 'factory construction + null-canvas early guard'.
Remove dead di stub entries (FRET_WIRE_HIT_*, getIsDestroyed,
updateStringHighlights) that no longer exist in the DI signature.

Suite: 427/427 (h3d glob).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014uZ169yfoFYArXz962g7KW
2026-09-06 07:21:01 +02:00
byrongamatosandClaude Sonnet 4.6 a0beb67b0d test(highway_3d): cut-16 scene-init — setter-call kill tests + execution smoke + pinned DI count
§10 kill tests added (10 source-scan assertions):
- initScene body calls setRen(, setScene(, setPNote(, setWrap(
- buildBoard body calls setBoardStringStartX(, setFretWireMats(
- _bgLoadSettings body calls setActivePalette(, setCameraMode(, setGlowMul(
- _bcSyncMode body calls setBcCtrl(
Each kills silently when its setter call is gutted — catches omission not
covered by the class-killer (which only catches assignment to DI param names).

§11 gate-2 execution smoke: new-Function harness with Proxy-based recording
DI stubs. With null canvas, initScene() returns false immediately (early
guard path). Documents WebGL gap: T.WebGLRenderer requires a real canvas;
source-scan kill tests cover the allocation paths. Sloppy-mode write gap
documented; ESLint no-undef compensates.

Anti-vacuity test updated: floor ≥150 kept; exact pinned count 183 added
(line-first-identifier extractor; comma-split total ~397 because many lines
pack pairs like 'getX, setX,' — both are counted in the comma-split).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014uZ169yfoFYArXz962g7KW
2026-09-06 06:52:36 +02:00
byrongamatosandClaude Sonnet 4.6 273412744a fix(h3d): cut-16 follow-up — tests, plugin.json bump, visibility/string-colors retargets
- Add tests/js/highway_3d_scene_init.test.js (18 tests): wiring guard,
  export surface, class-killer, DI anti-vacuity, import correctness,
  function presence, kill tests, plugin.json version gate.
- Bump plugins/highway_3d/plugin.json 3.51.0 → 3.52.0.
- Retarget highway_string_colors.test.js tests 3–4 to scene-init.js
  (functions moved in cut-16).
- Update highway_visibility.test.js test 22 regexes to accept DI-rewritten
  forms: getHighwayCanvas() / getWrap().style.display / getHighwayCanvas().offsetParent.

Suite: 1426/1427 pass (1 pre-existing audio test; all cut-16 regressions cleared).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014uZ169yfoFYArXz962g7KW
2026-09-06 06:46:08 +02:00