PR_26180_OWNER_019b-move-browser-shared-schemas-to-www#299
Conversation
There was a problem hiding this comment.
💡 Codex Review
For local validation with GAMEFOUNDRY_LOCAL_WEB_ROOT=repo-root, resolveStaticRouteTarget searches only the repository root, so /src/shared/schemas/tools/palette-browser.schema.json no longer resolves after the root copy was deleted and only this www/ copy exists. That configuration is still documented as the prior root-serving mode, so tools that fetch schema URLs under /src/shared/schemas/tools/... will 404 in that environment unless a root compatibility copy or route mapping is kept.
Moving replayContracts.js only into www/src/shared/contracts leaves dev/tests/shared/ContractIndexValidation.test.mjs unchanged: it still lists replayContracts.js as a legacy shared helper and asserts that src/shared/contracts/replayContracts.js exists. As a result node ./dev/scripts/run-node-test-files.mjs dev/tests/shared/ContractIndexValidation.test.mjs now fails; update that guard/list for the new browser-owned location or keep a root compatibility module.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const REPORT_DIR = path.join(ROOT, "docs", "dev", "reports"); | ||
| const SCHEMA_ROOT = path.join(ROOT, "tools", "schemas"); | ||
| const SCHEMA_ROOTS = [ | ||
| path.join(ROOT, "www", "src", "shared", "schemas"), |
There was a problem hiding this comment.
Keep JSON-contract CI from failing on moved schemas
When callers use --ci (for example dev/scripts/PS/validate-tool-schemas.ps1 -Ci), adding the moved www/src/shared/schemas tree to the schema index makes this script evaluate all 22 payload schemas with the old failure criteria: strictness inventory rows count as CI failures, and validateToolSchemas still requires root tool/version fields these schemas do not declare. node dev/scripts/validate-json-contracts.mjs --mode tools --ci now reports all 22 tool schemas invalid and exits 1, so the JSON-contract validation path is broken unless the CI criteria are updated for these moved schemas.
Useful? React with 👍 / 👎.
Summary
Moves the PR019a-audited active browser/runtime shared contract and tool schema files from root
src/shared/intowww/src/shared/.This preserves public browser route compatibility because the local/static web root serves
www/, so URLs such as/src/shared/schemas/tools/palette-browser.schema.jsonstill resolve towww/src/shared/schemas/tools/palette-browser.schema.json.Stack Context
PR_26180_OWNER_019a-contracts-schemas-obsolescence-auditPR_26180_OWNER_019a-contracts-schemas-obsolescence-auditPR_26180_OWNER_019b-move-browser-shared-schemas-to-wwwsrc/retirement PRsScope
www/src/shared/.Validation
node --check dev/scripts/validate-json-contracts.mjsPASSnode --check dev/tests/tools/ToolManifestBoundary.test.mjsPASSnode --check dev/tests/tools/ObjectVectorStudioV2DeleteCleanup.test.mjsPASSnode ./dev/scripts/run-node-test-files.mjs dev/tests/tools/ToolManifestBoundary.test.mjs dev/tests/dev-runtime/StaticWebRootCompatibility.test.mjsPASSnode ./node_modules/@playwright/test/cli.js test dev/tests/playwright/tools/StaticWebRootCompatibility.spec.mjs --config=dev/config/playwright.config.cjs --project=playwright --workers=1 --reporter=listPASSnpm run validate:canonical-structurePASSgit diff --checkPASSArtifacts
dev/reports/dev/workspace/zips/PR_26180_OWNER_019b-move-browser-shared-schemas-to-www_delta.zip