Skip to content

Commit 48020a9

Browse files
author
DavidQ
committed
Resolve two safe sample-local NO audit JSON artifacts (sample 1208 data intermediates) with targeted validation - PR 11.49
1 parent ab8a78b commit 48020a9

12 files changed

Lines changed: 199 additions & 4188 deletions

docs/dev/codex_commands.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,9 @@
1-
Replace script with upgraded version that shows referencing JS file.
1+
# Codex Commands - PR 11.49
2+
3+
Model: GPT-5.4
4+
Reasoning: high
5+
6+
```powershell
7+
codex --model gpt-5.4 --reasoning high "Run BUILD_PR_LEVEL_11_49_CONTROLLED_JSON_CLEANUP exactly as written. Use docs/pr/PR_11_49_CONTROLLED_JSON_CLEANUP/BUILD_PR.md as the source of truth. Run the audit script, select exactly two safe tool-specific NO JSON items, validate manually, apply only confirmed cleanup, run targeted checks, rerun audit, write reports under docs/dev/reports, update only status markers in the roadmap if execution-backed, and create the final repo-structured ZIP at C:\Users\davidq\Documents\GitHub\HTML-JavaScript-Gaming\tmp\PR_11_49_CONTROLLED_JSON_CLEANUP.zip. Do not run the full samples suite unless shared loader/framework files are changed."
8+
```
9+

docs/dev/commit_comment.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Upgrade audit script to show referencing JS file - PR 11.49
1+
Resolve two safe sample-local NO audit JSON artifacts (sample 1208 data intermediates) with targeted validation - PR 11.49
20.3 KB
Binary file not shown.
20.7 KB
Binary file not shown.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# PR 11.49 Prompt Notes
2+
3+
Use the upgraded audit script as signal only. The script does not decide deletion.
4+
5+
Decision rules:
6+
- If directly referenced by JS: keep.
7+
- If indirectly used by manifest/tool runtime: keep and document.
8+
- If clearly in wrong sample: move only when the destination is obvious and targeted validation supports it.
9+
- If no direct or indirect usage exists: delete.
10+
11+
Safe targets are tool-specific JSON payloads such as profiler, replay, pipeline, and 3D tool fixtures.
12+
13+
Do not touch palette, tile map editor document, or sample 1902 in this PR.
Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
# PR 11.49 Controlled JSON Cleanup Report
2+
3+
## Audit Before Summary
4+
- Source: `docs/dev/reports/PR_11_49_audit_before.txt`
5+
- JSON files scanned: 98
6+
- Referenced: 39
7+
- Missing reference (`NO`): 59
8+
9+
## Selected JSON Files
10+
Exactly two safe tool-specific `NO` JSON items were selected (excluded classes respected: no `palette.json`, no `tile-map-editor-document.json`, no sample `1902`):
11+
1. `samples/phase-12/1208/data/toolFormattedParallax.json`
12+
2. `samples/phase-12/1208/data/toolFormattedTileMap.json`
13+
14+
## Manual Validation Notes
15+
For each selected file, the required checks were performed:
16+
17+
### 1) `samples/phase-12/1208/data/toolFormattedParallax.json`
18+
- Filename reference search: no hits.
19+
- Basename reference search (`toolFormattedParallax`): no hits.
20+
- Owning sample inspection:
21+
- `samples/phase-12/1208/main.js` loads runtime scene directly; no reference to this file.
22+
- `samples/phase-12/1208/index.html` roundtrip links and sample tool launch paths use canonical `sample.1208.*.json` files.
23+
- `samples/phase-12/1208/sample.1208.parallax-editor.json` contains the active parallax tool payload.
24+
- Decision: `DELETE` (stale, non-referenced intermediate/export artifact).
25+
26+
### 2) `samples/phase-12/1208/data/toolFormattedTileMap.json`
27+
- Filename reference search: no hits.
28+
- Basename reference search (`toolFormattedTileMap`): no hits.
29+
- Owning sample inspection:
30+
- `samples/phase-12/1208/main.js` does not reference this file.
31+
- `samples/phase-12/1208/index.html` links tools via canonical `sample.1208.tile-map-editor.json`.
32+
- `samples/phase-12/1208/sample.1208.tile-map-editor.json` contains the active tilemap payload used for tool roundtrip.
33+
- Decision: `DELETE` (stale, non-referenced intermediate/export artifact).
34+
35+
## Action Taken Per File
36+
- Deleted `samples/phase-12/1208/data/toolFormattedParallax.json`
37+
- Deleted `samples/phase-12/1208/data/toolFormattedTileMap.json`
38+
39+
## Files Changed
40+
- Deleted: `samples/phase-12/1208/data/toolFormattedParallax.json`
41+
- Deleted: `samples/phase-12/1208/data/toolFormattedTileMap.json`
42+
- Added: `docs/dev/reports/PR_11_49_audit_before.txt`
43+
- Added: `docs/dev/reports/PR_11_49_audit_after.txt`
44+
- Added: `docs/dev/reports/PR_11_49_controlled_json_cleanup_report.md`
45+
- Updated: `docs/dev/commit_comment.txt`
46+
47+
## Targeted Validation Commands And Results
48+
- Audit before:
49+
- `powershell -ExecutionPolicy Bypass -Command ".\scripts\PS\audit-sample-json-js-references.ps1 | Tee-Object -FilePath 'docs/dev/reports/PR_11_49_audit_before.txt'"`
50+
- Result: PASS
51+
- Targeted sample check for affected sample:
52+
- `node ./tests/runtime/LaunchSmokeAllEntries.test.mjs --samples --sample-range=1208-1208`
53+
- Result: PASS (`PASS=1 FAIL=0 TOTAL=1`)
54+
- Audit after:
55+
- `powershell -ExecutionPolicy Bypass -Command ".\scripts\PS\audit-sample-json-js-references.ps1 | Tee-Object -FilePath 'docs/dev/reports/PR_11_49_audit_after.txt'"`
56+
- Result: PASS
57+
- `node --check` on changed JS files:
58+
- N/A (no JavaScript files changed in this PR scope)
59+
60+
## Full Samples Test Decision And Reason
61+
- Decision: skipped
62+
- Reason: this PR only removes two sample-local stale JSON artifacts and does not modify shared loader/framework code.
63+
64+
## Audit After Summary
65+
- Source: `docs/dev/reports/PR_11_49_audit_after.txt`
66+
- JSON files scanned: 96
67+
- Referenced: 39
68+
- Missing reference (`NO`): 57
69+
- Net change vs before: 2 stale `NO` JSON items removed.
70+
71+
## Roadmap Status Marker Update
72+
- No roadmap status marker update was required for this execution.
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# Launch Smoke Report
22

3-
Generated: 2026-04-29T20:19:41.376Z
3+
Generated: 2026-04-29T20:34:40.651Z
44

5-
Filters: games=false, samples=true, tools=false, sampleRange=0708-0708
5+
Filters: games=false, samples=true, tools=false, sampleRange=1208-1208
66

77
| Status | Type | Label | Path | Notes | Steps |
88
| --- | --- | --- | --- | --- | --- |
9-
| PASS | sample | 0708 | samples\phase-07\0708\index.html | | npm install --prefix ./tmp ws → npm run test:launch-smoke |
9+
| PASS | sample | 1208 | samples\phase-12\1208\index.html | | npm install --prefix ./tmp ws → npm run test:launch-smoke |

docs/dev/reports/sample_json_js_reference_audit.csv

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,6 @@
5757
"samples\phase-12\1205","samples\phase-12\1205\sample.1205.parallax-editor.json","False","","",""
5858
"samples\phase-12\1205","samples\phase-12\1205\sample.1205.vector-map-editor.json","False","","",""
5959
"samples\phase-12\1208","samples\phase-12\1208\assets\data\tileset\demo1208-terrain-tileset.sprite-editor.json","False","","",""
60-
"samples\phase-12\1208","samples\phase-12\1208\data\toolFormattedParallax.json","False","","",""
61-
"samples\phase-12\1208","samples\phase-12\1208\data\toolFormattedTileMap.json","False","","",""
6260
"samples\phase-12\1208","samples\phase-12\1208\sample.1208.3d-asset-viewer.json","False","","",""
6361
"samples\phase-12\1208","samples\phase-12\1208\sample.1208.3d-json-payload-normalizer.json","False","","",""
6462
"samples\phase-12\1208","samples\phase-12\1208\sample.1208.palette.json","False","","",""
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# BUILD_PR_LEVEL_11_49_CONTROLLED_JSON_CLEANUP
2+
3+
## Objective
4+
Execute the next controlled cleanup batch by resolving exactly two safe `NO` JSON audit findings.
5+
6+
## Required Steps
7+
1. Confirm clean working tree or record current state.
8+
2. Run:
9+
```powershell
10+
.\scripts\PS\audit-sample-json-js-references.ps1 | Tee-Object -FilePath docs\dev\reports\PR_11_49_audit_before.txt
11+
```
12+
3. Select exactly two safe tool-specific `NO` JSON files.
13+
4. Do not select excluded files:
14+
- `palette.json`
15+
- `tile-map-editor-document.json`
16+
- anything under sample `1902`
17+
5. For each selected JSON file:
18+
- search for filename references
19+
- search for basename references
20+
- inspect the owning sample/tool JS
21+
- decide keep, move, or delete
22+
6. Apply only confirmed corrections.
23+
7. Run targeted validation for the affected files/samples/tools.
24+
8. Rerun audit and save:
25+
```powershell
26+
.\scripts\PS\audit-sample-json-js-references.ps1 | Tee-Object -FilePath docs\dev\reports\PR_11_49_audit_after.txt
27+
```
28+
9. Write final evidence report to:
29+
`docs/dev/reports/PR_11_49_controlled_json_cleanup_report.md`
30+
10. Update `docs/dev/commit_comment.txt` if the final PR description changes.
31+
32+
## Constraints
33+
- No implementation refactors.
34+
- No mass cleanup.
35+
- No silent default payloads.
36+
- No hardcoded hidden fallback assets.
37+
- No unrelated files.
38+
- No roadmap text edits except status-only transitions when execution-backed.
39+
- Preserve exact file names unless moving a file is the chosen correction.
40+
41+
## Evidence Report Required Sections
42+
- Audit before summary
43+
- Selected JSON files
44+
- Manual validation notes
45+
- Action taken per file
46+
- Files changed
47+
- Targeted validation commands and results
48+
- Full samples test decision and reason
49+
- Audit after summary
50+
51+
## Full Sample Suite Decision
52+
Default: skipped.
53+
54+
Reason: this PR is limited to sample/tool-specific JSON cleanup and does not modify shared loader/framework code.
55+
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# PLAN_PR_LEVEL_11_49_CONTROLLED_JSON_CLEANUP
2+
3+
## Purpose
4+
Continue controlled sample JSON cleanup using the audit signal, limited to two safe tool-specific `NO` items.
5+
6+
## Mode
7+
CONTROLLED CLEANUP MODE.
8+
9+
This PR is not a refactor, not a mass delete, and not a tooling expansion.
10+
11+
## Scope
12+
- Run `scripts/PS/audit-sample-json-js-references.ps1`.
13+
- Select exactly two `NO` JSON files that are tool-specific and clearly safe.
14+
- Prefer safe tool-specific payloads such as profiler, replay, pipeline, 3D utility/tool payloads.
15+
- Manually inspect each selected JSON file and nearby JS/tool references before modifying anything.
16+
- For each selected item, decide one of:
17+
- indirectly used → keep and document why
18+
- wrong sample/location → move only if clearly correct
19+
- dead/unreferenced → delete only when confirmed
20+
- Update roadmap status markers only if there is an execution-backed cleanup roadmap item already present.
21+
22+
## Explicit Exclusions
23+
Do not touch:
24+
- `palette.json`
25+
- `tile-map-editor-document.json`
26+
- sample `1902`
27+
- roadmap text except status marker transitions `[ ] -> [.]` or `[.] -> [x]`
28+
- shared loader/framework files unless required to validate a selected item
29+
30+
## Acceptance Criteria
31+
- Audit script was run and output captured in `docs/dev/reports/PR_11_49_audit_before.txt`.
32+
- Exactly two safe `NO` items were selected and documented.
33+
- Each selected item has a manual validation note.
34+
- Any delete/move is supported by no JS references and no indirect usage found.
35+
- Targeted validation is run only for affected samples/tools.
36+
- Full sample suite is skipped unless shared loader/framework changes are made.
37+
- Final report documents changed files, test commands, and full-suite decision.
38+
39+
## Testing Rule
40+
Do not run the full samples smoke test by default. It takes about 20 minutes.
41+
42+
Run only targeted checks:
43+
- syntax checks for changed JS/JSON files
44+
- affected sample/tool launch checks if available
45+
- rerun audit script after changes
46+

0 commit comments

Comments
 (0)