Skip to content

Commit 89f4905

Browse files
committed
Merge origin/main into PR_26174_ALFA_000
2 parents dbb8580 + dd72e83 commit 89f4905

3 files changed

Lines changed: 368 additions & 1 deletion

File tree

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,12 @@
1313
# Ignore the NEXT_COMMAND.txt file
1414
NEXT_COMMAND.txt
1515

16-
# Ignore the tests results and temporary files
16+
# Ignore generated dependency, test result, and temporary files
1717
node_modules/
1818
tests/results/
19+
tests/results/**
1920
tmp/test-results/
21+
tmp/test-results/**
2022
tmp/
2123
scripts/untracked/
2224
projects/
Lines changed: 236 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,236 @@
1+
# PR_26172_CHARLIE_001 Repository Compliance Audit
2+
3+
## Scope
4+
5+
Audit repository compliance against:
6+
7+
- PR_034 Canonical Repository Structure
8+
- PR_035 Test Structure Standardization
9+
- PR_036 Legacy Migration Policy
10+
11+
Reviewed areas:
12+
13+
- `toolbox/`
14+
- `assets/`
15+
- `tests/`
16+
- `api/`
17+
- `serverside/`
18+
- `src/engine/`
19+
20+
This PR is audit-only. No executable implementation changes were made.
21+
22+
## Team Ownership
23+
24+
- TEAM token: CHARLIE
25+
- Ownership classification: governance / repository compliance / diagnostics
26+
- TEAM ownership result: PASS
27+
28+
## Branch Validation
29+
30+
| Requirement | Status | Evidence |
31+
| --- | --- | --- |
32+
| Started from latest main | PASS | `main` was pulled before branch creation; source commit `c4a495f0aa8e32d499ca64555c4a3547e6fcb298`. |
33+
| Worktree clean before branch | PASS | `git status --short` returned no output before branch creation. |
34+
| Local/origin sync before branch | PASS | `git rev-list --left-right --count HEAD...origin/main` returned `0 0`. |
35+
| PR branch created from main | PASS | Branch `pr/26172-CHARLIE-001-repository-compliance-audit` was created from latest `main`. |
36+
| Runtime/source edits avoided | PASS | Planned changed files are reports only under `docs_build/dev/reports/`. |
37+
38+
## Repository Area Results
39+
40+
| Area | Status | Findings |
41+
| --- | --- | --- |
42+
| `toolbox/` | FAIL | Active tool JavaScript remains beside tool HTML entries instead of canonical `assets/toolbox/{tool-name}/js/index.js` or shared asset roots. |
43+
| `assets/` | PASS | No non-compliant JS or CSS files were found in `assets/`; scanned JS/CSS lives under `assets/theme-v2/`. |
44+
| `tests/` | FAIL | 494 files are in non-canonical top-level test locations outside `tests/toolbox/`, `tests/engine/`, `tests/api/`, `tests/server/`, `tests/js/shared/`, or `tests/regression/`. |
45+
| `api/` | FAIL | Canonical root is absent. No API files were found to classify, but the expected top-level API area is not physically present. |
46+
| `serverside/` | FAIL | Canonical root is absent. No serverside files were found to classify, but the expected top-level serverside area is not physically present. |
47+
| `src/engine/` | FAIL | Most engine JS is under feature folders, but `src/engine/paletteList.js` is a root-level JS file and `src/engine/ui/*.css` contains CSS outside canonical asset/theme roots. |
48+
49+
## Non-Compliant JS Locations
50+
51+
### `toolbox/`
52+
53+
These active JavaScript files are outside the canonical tool asset structure:
54+
55+
- `toolbox/assets/assets-api-client.js`
56+
- `toolbox/assets/assets-upload-worker.js`
57+
- `toolbox/assets/assets.js`
58+
- `toolbox/colors/colors.js`
59+
- `toolbox/colors/palette-api-client.js`
60+
- `toolbox/controls/controls-api-client.js`
61+
- `toolbox/controls/controls.js`
62+
- `toolbox/game-configuration/game-configuration-api-client.js`
63+
- `toolbox/game-configuration/game-configuration.js`
64+
- `toolbox/game-design/game-design-api-client.js`
65+
- `toolbox/game-design/game-design.js`
66+
- `toolbox/game-hub/game-hub-api-client.js`
67+
- `toolbox/game-hub/game-hub.js`
68+
- `toolbox/game-journey/game-journey-api-client.js`
69+
- `toolbox/game-journey/game-journey.js`
70+
- `toolbox/idea-board/index.js`
71+
- `toolbox/messages/message-tts-service-registry.js`
72+
- `toolbox/messages/messages-api-client.js`
73+
- `toolbox/messages/messages.js`
74+
- `toolbox/objects/objects-api-client.js`
75+
- `toolbox/objects/objects.js`
76+
- `toolbox/tags/tags-api-client.js`
77+
- `toolbox/tags/tags.js`
78+
- `toolbox/text-to-speech/text2speech.js`
79+
- `toolbox/tool-registry-api-client.js`
80+
- `toolbox/toolRegistry.js`
81+
- `toolbox/tools-page-accordions.js`
82+
83+
Recommended target pattern:
84+
85+
- Tool-specific JS: `assets/toolbox/{tool-name}/js/index.js`
86+
- Shared toolbox JS: `assets/js/shared/`
87+
88+
### `src/engine/`
89+
90+
- `src/engine/paletteList.js`
91+
92+
Recommended target pattern:
93+
94+
- Move under a feature folder such as `src/engine/palette/` after import-impact review.
95+
96+
## Non-Compliant CSS Locations
97+
98+
### `toolbox/`
99+
100+
- None found.
101+
102+
### `assets/`
103+
104+
- None found.
105+
106+
### `src/engine/`
107+
108+
These CSS files are active style assets under engine source:
109+
110+
- `src/engine/ui/baseLayout.css`
111+
- `src/engine/ui/hubCommon.css`
112+
- `src/engine/ui/spriteEditor.css`
113+
114+
Recommended target pattern:
115+
116+
- Move shared UI/theme styling into `assets/theme-v2/css/` or create an approved engine UI style policy before relocation.
117+
118+
## Non-Compliant Test Locations
119+
120+
Canonical test roots from PR_035:
121+
122+
- `tests/toolbox/{tool-name}/`
123+
- `tests/engine/{feature-name}/`
124+
- `tests/api/{feature-name}/`
125+
- `tests/server/{feature-name}/`
126+
- `tests/js/shared/`
127+
- `tests/regression/`
128+
129+
The audit found 494 files in non-canonical test locations:
130+
131+
| Path | File Count | Examples |
132+
| --- | ---: | --- |
133+
| `tests/ai/` | 1 | `tests/ai/AIBehaviors.test.mjs` |
134+
| `tests/assets/` | 1 | `tests/assets/AssetLoaderSystem.test.mjs` |
135+
| `tests/audio/` | 1 | `tests/audio/AudioService.test.mjs` |
136+
| `tests/combat/` | 1 | `tests/combat/Combat.test.mjs` |
137+
| `tests/config/` | 1 | `tests/config/ConfigStore.test.mjs` |
138+
| `tests/core/` | 11 | `tests/core/EngineCoreBoundaryBaseline.test.mjs` |
139+
| `tests/dev-runtime/` | 31 | `tests/dev-runtime/AdminHealthOperations.test.mjs` |
140+
| `tests/entity/` | 1 | `tests/entity/Entity.test.mjs` |
141+
| `tests/events/` | 2 | `tests/events/EventBus.test.mjs` |
142+
| `tests/final/` | 11 | `tests/final/ReleaseReadinessSystems.test.mjs` |
143+
| `tests/fixtures/` | 52 | `tests/fixtures/assets/asset-scenarios.json` |
144+
| `tests/fx/` | 1 | `tests/fx/ParticleSystem.test.mjs` |
145+
| `tests/games/` | 35 | `tests/games/AsteroidsValidation.test.mjs` |
146+
| `tests/helpers/` | 11 | `tests/helpers/playwrightRepoServer.mjs` |
147+
| `tests/index.html` | 1 | `tests/index.html` |
148+
| `tests/input/` | 8 | `tests/input/InputService.test.mjs` |
149+
| `tests/persistence/` | 1 | `tests/persistence/StorageService.test.mjs` |
150+
| `tests/playwright/` | 44 | `tests/playwright/tools/GameJourneyTool.spec.mjs` |
151+
| `tests/playwright_installation.txt` | 1 | `tests/playwright_installation.txt` |
152+
| `tests/production/` | 3 | `tests/production/ProductionReadiness.test.mjs` |
153+
| `tests/README.md` | 1 | `tests/README.md` |
154+
| `tests/render/` | 1 | `tests/render/Renderer.test.mjs` |
155+
| `tests/replay/` | 2 | `tests/replay/ReplaySystem.test.mjs` |
156+
| `tests/results/` | 26 | `tests/results/playwright-results.json` |
157+
| `tests/run-tests.mjs` | 1 | `tests/run-tests.mjs` |
158+
| `tests/runtime/` | 81 | `tests/runtime/V2SessionPersistence.test.mjs` |
159+
| `tests/samples/` | 1 | `tests/samples/FullscreenRuleEnforcement.test.mjs` |
160+
| `tests/scenes/` | 3 | `tests/scenes/SceneManager.test.mjs` |
161+
| `tests/schemas/` | 1 | `tests/schemas/tool.manifest.schema.json` |
162+
| `tests/shared/` | 92 | `tests/shared/ProjectContract.test.mjs` |
163+
| `tests/testRunner.html` | 1 | `tests/testRunner.html` |
164+
| `tests/testRunner.js` | 1 | `tests/testRunner.js` |
165+
| `tests/tools/` | 57 | `tests/tools/ToolBoundaryEnforcement.test.mjs` |
166+
| `tests/validation/` | 3 | `tests/validation/samples.runtime.validation.report.json` |
167+
| `tests/vector/` | 1 | `tests/vector/VectorMath.test.mjs` |
168+
| `tests/world/` | 4 | `tests/world/WorldSystems.test.mjs` |
169+
170+
Generated Playwright result artifacts under `tests/results/` should be treated as cleanup/archive candidates rather than active test source.
171+
172+
## Legacy Migration Candidates
173+
174+
| Priority | Candidate | Reason | Recommended Handling |
175+
| --- | --- | --- | --- |
176+
| P0 | `tests/results/` | Generated result artifacts are tracked under active tests. | Move to ignored output or archive/report storage after owner approval. |
177+
| P1 | `toolbox/*/*.js` and shared `toolbox/*.js` | Active JS is colocated with HTML entries instead of canonical asset roots. | Migrate tool JS to `assets/toolbox/{tool-name}/js/index.js`; migrate shared JS to `assets/js/shared/`. |
178+
| P1 | `tests/dev-runtime/`, `tests/playwright/`, `tests/runtime/`, `tests/shared/`, `tests/tools/` | Large active test buckets conflict with PR_035 canonical test roots. | Split by ownership into `tests/toolbox/`, `tests/engine/`, `tests/api/`, `tests/server/`, `tests/js/shared/`, and `tests/regression/`. |
179+
| P2 | `src/engine/paletteList.js` | Root-level engine JS file is outside `src/engine/{feature-name}/`. | Move to an approved feature folder with import compatibility reviewed. |
180+
| P2 | `src/engine/ui/*.css` | CSS lives under engine source instead of theme/tool asset roots. | Move to `assets/theme-v2/css/` or define an explicit engine UI CSS policy. |
181+
| P3 | Missing `api/` and `serverside/` roots | Canonical target roots are absent. | Create roots when the first API/server migration needs them, with placeholder README only if governance permits. |
182+
183+
## Prioritized Remediation List
184+
185+
1. Remove or archive tracked generated artifacts under `tests/results/`.
186+
2. Create a staged migration plan for `toolbox/` JavaScript sidecars, starting with shared files (`toolRegistry.js`, `tool-registry-api-client.js`, `tools-page-accordions.js`).
187+
3. Standardize high-volume test buckets in phases: `tests/dev-runtime/`, `tests/playwright/`, `tests/runtime/`, `tests/shared/`, then `tests/tools/`.
188+
4. Move `src/engine/paletteList.js` into an engine feature folder after import-impact review.
189+
5. Resolve engine CSS placement for `src/engine/ui/*.css`.
190+
6. Add or defer canonical `api/` and `serverside/` roots with explicit owner-approved scope.
191+
192+
## Recommended Next Charlie PRs
193+
194+
- `PR_26172_CHARLIE_002-test-results-artifact-cleanup-plan`
195+
- `PR_26172_CHARLIE_003-toolbox-js-canonical-asset-migration-plan`
196+
- `PR_26172_CHARLIE_004-test-structure-standardization-plan`
197+
- `PR_26172_CHARLIE_005-engine-root-js-and-css-migration-plan`
198+
- `PR_26172_CHARLIE_006-api-serverside-root-readiness-plan`
199+
200+
## Requirement Checklist
201+
202+
| Requirement | Status | Evidence |
203+
| --- | --- | --- |
204+
| Follow ProjectInstructions | PASS | Read active `docs_build/dev/ProjectInstructions/` governance before work. |
205+
| Start from latest main | PASS | Main pulled and branch created from `c4a495f0aa8e32d499ca64555c4a3547e6fcb298`. |
206+
| Worktree clean before work | PASS | `git status --short` returned no output before edits. |
207+
| Audit PR_034 structure | PASS | Compared scoped paths to canonical toolbox, assets, engine, API, and serverside roots. |
208+
| Audit PR_035 tests | PASS | Compared `tests/` contents to canonical test roots. |
209+
| Audit PR_036 legacy migration policy | PASS | Classified migration candidates without moving or deleting files. |
210+
| Review `toolbox/` | PASS | Identified 27 non-compliant JS files. |
211+
| Review `assets/` | PASS | Found no non-compliant active JS/CSS in `assets/`. |
212+
| Review `tests/` | PASS | Identified 494 files in non-canonical test locations. |
213+
| Review `api/` | PASS | Directory absent; recorded as structural failure. |
214+
| Review `serverside/` | PASS | Directory absent; recorded as structural failure. |
215+
| Review `src/engine/` | PASS | Identified root JS and engine CSS placement issues. |
216+
| No executable implementation changes | PASS | Audit/report-only scope. |
217+
| Create audit report | PASS | This file. |
218+
| Create standard Codex reports | PASS | `docs_build/dev/reports/codex_review.diff` and `docs_build/dev/reports/codex_changed_files.txt` exist. |
219+
| Create ZIP artifact | PASS | `tmp/PR_26172_CHARLIE_001-repository-compliance-audit_delta.zip` exists. |
220+
221+
## Validation Lane Report
222+
223+
- `git diff --check`: PASS.
224+
- Report exists: PASS.
225+
- Required Codex reports exist: PASS.
226+
- ZIP artifact exists: PASS.
227+
- Runtime source files changed: PASS, changed files are limited to `docs_build/dev/reports/`.
228+
- Playwright: SKIP, audit-only documentation/report PR.
229+
- Samples: SKIP, audit-only documentation/report PR.
230+
231+
## Manual Validation Notes
232+
233+
- The audit intentionally did not move files, delete generated artifacts, create canonical roots, or modify executable source.
234+
- `api/` and `serverside/` were missing from the working tree; this was recorded as a structural finding, not remediated in this PR.
235+
- Non-canonical test locations were counted by top-level path under `tests/` to keep the report actionable without rewriting the test tree.
236+
- Tracked generated artifacts under `tests/results/` are listed as a high-priority cleanup candidate because they are active repository files but not active test source.
Lines changed: 129 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,129 @@
1+
# PR_26172_CHARLIE_002 Test Results Artifact Cleanup
2+
3+
## Scope
4+
5+
Clean up generated test result artifacts under `tests/results/` after the Charlie repository compliance audit identified that path as a high-priority cleanup candidate.
6+
7+
Source audit:
8+
9+
- `docs_build/dev/reports/PR_26172_CHARLIE_001-repository-compliance-audit.md`
10+
11+
This PR does not modify runtime source and does not move unrelated tests.
12+
13+
## Team Ownership
14+
15+
- TEAM token: CHARLIE
16+
- Ownership classification: governance / repository hygiene / diagnostics
17+
- TEAM ownership result: PASS
18+
19+
## Branch Validation
20+
21+
| Requirement | Status | Evidence |
22+
| --- | --- | --- |
23+
| Started from latest main | PASS | `main` was pulled before branch creation; source commit `f2b50ac9d79256df3a7716ac4eff21f3a4303bb3`. |
24+
| Worktree clean before branch | PASS | `git status --short` returned no output before branch creation. |
25+
| Local/origin sync before branch | PASS | `git rev-list --left-right --count HEAD...origin/main` returned `0 0`. |
26+
| PR branch created from main | PASS | Branch `pr/26172-CHARLIE-002-test-results-artifact-cleanup` was created from latest `main`. |
27+
28+
## Files Reviewed
29+
30+
`git ls-files tests/results` returned no tracked files.
31+
32+
The local ignored `tests/results/` folder contained generated Playwright/report output:
33+
34+
- `tests/results/artifacts/.last-run.json`
35+
- `tests/results/artifacts/tools-MidiStudioV2-MIDI-St-3c5a9-multi-song-manifest-payload-playwright/trace.zip`
36+
- `tests/results/artifacts/tools-MidiStudioV2-MIDI-St-752e4-on-and-timeline-scroll-sync-playwright/trace.zip`
37+
- `tests/results/artifacts/tools-MidiStudioV2-MIDI-St-c50c5-m-Tool-Mode-standalone-save-playwright/trace.zip`
38+
- `tests/results/playwright-results.json`
39+
- `tests/results/report/data/09daf0cfe8750af5e9e5bb22161367f97296f4fd.zip`
40+
- `tests/results/report/data/a9ba8bc1c6a629055b981a6f385fa4de3e42a79d.zip`
41+
- `tests/results/report/data/b1dc1da730cbd5e9adc334a6f385fa4de3e42a79d.zip`
42+
- `tests/results/report/data/c150573559f5367f4ec5724abb7a55798abcdff9.zip`
43+
- `tests/results/report/index.html`
44+
- `tests/results/report/trace/assets/codeMirrorModule-DS0FLvoc.js`
45+
- `tests/results/report/trace/assets/defaultSettingsView-GTWI-W_B.js`
46+
- `tests/results/report/trace/codeMirrorModule.DYBRYzYX.css`
47+
- `tests/results/report/trace/codicon.DCmgc-ay.ttf`
48+
- `tests/results/report/trace/defaultSettingsView.B4dS75f0.css`
49+
- `tests/results/report/trace/index.C5466mMT.js`
50+
- `tests/results/report/trace/index.CzXZzn5A.css`
51+
- `tests/results/report/trace/index.html`
52+
- `tests/results/report/trace/manifest.webmanifest`
53+
- `tests/results/report/trace/playwright-logo.svg`
54+
- `tests/results/report/trace/snapshot.html`
55+
- `tests/results/report/trace/sw.bundle.js`
56+
- `tests/results/report/trace/uiMode.Btcz36p_.css`
57+
- `tests/results/report/trace/uiMode.Vipi55dB.js`
58+
- `tests/results/report/trace/uiMode.html`
59+
- `tests/results/report/trace/xtermModule.DYP7pi_n.css`
60+
61+
## Files Removed Or Retained
62+
63+
| Category | Status | Notes |
64+
| --- | --- | --- |
65+
| Tracked files under `tests/results/` | None removed | No tracked files existed under `tests/results/`. |
66+
| Local ignored generated artifacts under `tests/results/` | Removed from workspace | Removed only after verifying the resolved target path was inside the repository. |
67+
| Active test source | Retained | No active test source was found under `tests/results/`. |
68+
| Fixture or baseline data | Retained | No committed fixture or baseline dependency was found under `tests/results/`. |
69+
70+
## Reference And Dependency Check
71+
72+
| Check | Status | Evidence |
73+
| --- | --- | --- |
74+
| Active tracked files under `tests/results/` | PASS | `git ls-files tests/results` returned no output. |
75+
| Tracked ignored files under `tests/results/` | PASS | `git ls-files -c -i --exclude-standard tests/results` returned no output. |
76+
| Ignored local generated files under `tests/results/` | PASS | `git ls-files -o -i --exclude-standard tests/results` listed only Playwright/report artifacts. |
77+
| Active config uses `tmp/test-results/` | PASS | `playwright.config.cjs` writes output, artifacts, HTML report, and JSON report under `tmp/test-results/`. |
78+
| Active references to `tests/results/` | PASS | Active config/test/docs search returned no required source or fixture dependency. |
79+
| Historical references retained | PASS | References in `archive/` and historical `docs_build/dev/reports/` were not modified. |
80+
81+
## Ignore Rule Changes
82+
83+
Updated `.gitignore` to make generated test-output protection explicit:
84+
85+
- Kept `tests/results/`.
86+
- Added `tests/results/**`.
87+
- Kept `tmp/test-results/`.
88+
- Added `tmp/test-results/**`.
89+
- Confirmed `tmp/` remains ignored.
90+
91+
Ignore probe:
92+
93+
- `git check-ignore -v tests/results/probe.txt` resolves to `.gitignore`.
94+
- `git check-ignore -v tmp/test-results/probe.txt` resolves to `.gitignore`.
95+
96+
## Requirement Checklist
97+
98+
| Requirement | Status | Evidence |
99+
| --- | --- | --- |
100+
| Confirm Project Instructions were reviewed | PASS | Read `docs_build/dev/ProjectInstructions/README.txt`, `PROJECT_INSTRUCTIONS.md`, branch/workflow governance, team ownership, and artifact/reporting rules. |
101+
| Use PR_26172_CHARLIE_001 findings | PASS | This cleanup is based on the P0 `tests/results/` finding. |
102+
| Review `tests/results/` | PASS | Reviewed tracked, ignored, and local generated contents. |
103+
| Confirm generated artifacts, not active source | PASS | Files were Playwright JSON, HTML report, trace assets, and zipped trace/report data. |
104+
| Search references to `tests/results/` files | PASS | No active source/fixture dependency found; historical references retained. |
105+
| Remove tracked generated artifacts if safe | PASS | No tracked generated artifacts existed to remove. |
106+
| Add/update ignore rules | PASS | `.gitignore` now explicitly includes `tests/results/**` and `tmp/test-results/**`. |
107+
| Do not remove active test source | PASS | No active test source removed. |
108+
| Do not modify runtime source | PASS | No runtime source changed. |
109+
| Do not move unrelated tests | PASS | No test files were moved. |
110+
| Stop gate not triggered | PASS | No `tests/results/` file was required as active source, fixture data, or committed baseline data. |
111+
| Create required reports | PASS | `docs_build/dev/reports/codex_review.diff` and `docs_build/dev/reports/codex_changed_files.txt` exist. |
112+
| Create ZIP artifact | PASS | `tmp/PR_26172_CHARLIE_002-test-results-artifact-cleanup_delta.zip` exists. |
113+
114+
## Validation Lane Report
115+
116+
- `git diff --check`: PASS.
117+
- Cleanup limited to generated artifacts under `tests/results/`: PASS.
118+
- Ignore rule prevents recommit: PASS.
119+
- Runtime source files changed: PASS, no runtime source files changed.
120+
- Required reports exist: PASS.
121+
- ZIP artifact exists: PASS.
122+
- Playwright: SKIP, ignore/report-only cleanup with no active test or runtime source changes.
123+
- Samples: SKIP, no sample files changed.
124+
125+
## Manual Validation Notes
126+
127+
- The local ignored `tests/results/` directory was deleted from the workspace only after path verification showed it was inside the repository root.
128+
- Repository history already contains `docs_build/dev/reports/docs_archive_test_output_cleanup_report.md`, which documents the prior migration of generated test output from `tests/results/` to `tmp/test-results/`.
129+
- This PR preserves historical report/archive references and only hardens the active ignore rule.

0 commit comments

Comments
 (0)