Skip to content

fix(starter): pin compatible Vite release - #127

Merged
imjlk merged 4 commits into
mainfrom
codex/fix-create-game-starter
Aug 10, 2026
Merged

imjlk merged 4 commits into
mainfrom
codex/fix-create-game-starter

Conversation

@imjlk

@imjlk imjlk commented Aug 3, 2026 •

Copy link
Copy Markdown
Owner

What changed

  • pin Vite 8.1.3 in the Phaser starter and every generated target wrapper
  • keep the checked-in starter example on the same verified version
  • validate that generated starter packages use one exact Vite pin
  • add a Sampo patch changeset for @mpgd/cli

Why

Fresh standalone games resolved vite: ^8.1.3 to newer patch releases. Vite 8.1.5 causes TypeScript 7 RC to exceed its recursive comparison depth while checking the @ttsc/unplugin and target-wrapper plugin types, so an untouched generated game fails pnpm check immediately.

Validation

  • pnpm validate:starter-workflow
  • pnpm --dir examples/phaser-starter check
  • generated a fresh standalone game from the source CLI, installed public @mpgd/* packages, and passed root, Devvit, Cloudflare Pages, and Apps in Toss checks plus the production Vite build
  • pnpm check
  • git diff --check
  • global ocr review --audience agent --commit 8e42df2 completed with no findings

Summary by CodeRabbit

  • Bug Fixes

    • Generated Phaser starters now display a clear, accessible error panel when game modules fail to load, instead of failing silently.
    • Improved startup error handling across supported starter targets, with refresh guidance for recovery.
  • Compatibility

    • Vite versions are now pinned to verified releases in generated starters for more reliable development and typechecking.
    • Starter tooling now avoids excessive TypeScript plugin-type recursion during monorepo checks.
  • Validation

    • Automated checks now verify dependency pinning, error handling, accessibility messaging, and consistency between templates and examples.

@coderabbitai

coderabbitai Bot commented Aug 3, 2026 •

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@imjlk, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 50 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 460a8ded-ffd7-4595-8d3b-5321fefa5dd6

📥 Commits

Reviewing files that changed from the base of the PR and between 43a1936 and 0fb4062.

📒 Files selected for processing (1)
  • tools/validate-starter-workflow.ts
📝 Walkthrough

Walkthrough

The Phaser example and generated starters now pin Vite 8.1.3, bound ttsc to PluginOption, handle dynamic entry import failures, render an accessible fallback, and validate parity across starter implementations.

Changes

Phaser starter hardening

Layer / File(s) Summary
Entry failure handling
examples/phaser-starter/src/entry.ts, examples/phaser-starter/src/gameEntry.ts, examples/phaser-starter/src/runtime/renderEntryFailure.ts, packages/cli/templates/phaser-game/src/entry.ts, packages/cli/templates/phaser-game/src/gameEntry.ts, packages/cli/templates/phaser-game/src/runtime/renderEntryFailure.ts
Both starter implementations catch dynamic import failures. renderEntryFailure logs the error and renders an accessible refresh message in #game.
Vite version and plugin typing
examples/phaser-starter/package.json, examples/phaser-starter/vite.shared.ts, packages/cli/templates/phaser-game/package.json, packages/cli/templates/phaser-game/apps/*/package.json, packages/cli/templates/phaser-game/vite.shared.ts
Starter manifests pin Vite to 8.1.3. Shared Vite configurations cast the ttsc plugin to PluginOption.
Workflow validation and release metadata
tools/validate-starter-workflow.ts, .sampo/changesets/*.md
Workflow checks enforce exact Vite pins, bounded plugin typing, failure handling, accessible messaging, and parity between template and example helpers. Three patch changesets document the updates.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Possibly related PRs

Poem

A rabbit finds the loading trail,
And catches errors in its sail.
Vite stands pinned, plugins stay neat,
A bright alert makes startup sweet.
“Refresh,” it says, with ears held high.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: pinning a compatible Vite release in the starter.
Description check ✅ Passed The description explains the changes, motivation, release impact, and extensive validation, although its headings differ from the repository template.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/fix-create-game-starter

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@imjlk
imjlk force-pushed the codex/fix-create-game-starter branch from a6d1e1d to 43a1936 Compare August 10, 2026 16:48

imjlk commented Aug 10, 2026

Copy link
Copy Markdown
Owner Author

@codex review

최신 main 기준으로 리베이스했고 로컬 pnpm check, starter workflow 검증, 예제 타입체크, git diff --check, OCR 재리뷰를 통과했습니다. 새 head를 기준으로 재검토 부탁드립니다.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@tools/validate-starter-workflow.ts`:
- Around line 317-343: Update the Vite version validation in the package-path
loop to compare every devDependencies.vite value directly against the fixed
baseline 8.1.3, rather than initializing and reusing expectedVersion from the
first manifest. Remove the first-value baseline logic while preserving the
existing format validation and failure reporting.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 834852a0-92c4-478e-823a-c631c9501abb

📥 Commits

Reviewing files that changed from the base of the PR and between 9b4e1d4 and 43a1936.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (17)
  • .sampo/changesets/bound-starter-vite-plugin-type.md
  • .sampo/changesets/pin-generated-vite.md
  • .sampo/changesets/render-starter-entry-failure.md
  • examples/phaser-starter/package.json
  • examples/phaser-starter/src/entry.ts
  • examples/phaser-starter/src/gameEntry.ts
  • examples/phaser-starter/src/runtime/renderEntryFailure.ts
  • examples/phaser-starter/vite.shared.ts
  • packages/cli/templates/phaser-game/apps/target-ait/package.json
  • packages/cli/templates/phaser-game/apps/target-cloudflare-pages/package.json
  • packages/cli/templates/phaser-game/apps/target-devvit/package.json
  • packages/cli/templates/phaser-game/package.json
  • packages/cli/templates/phaser-game/src/entry.ts
  • packages/cli/templates/phaser-game/src/gameEntry.ts
  • packages/cli/templates/phaser-game/src/runtime/renderEntryFailure.ts
  • packages/cli/templates/phaser-game/vite.shared.ts
  • tools/validate-starter-workflow.ts

Comment thread tools/validate-starter-workflow.ts Resolved
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🚀

Reviewed commit: 43a19368ad

ℹ️ 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".

imjlk commented Aug 10, 2026

Copy link
Copy Markdown
Owner Author

@codex review

CodeRabbit의 Vite baseline 지적을 0fb4062에서 수정했습니다. 최신 head 기준 재검토 부탁드립니다.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. What shall we delve into next?

Reviewed commit: 0fb4062cd6

ℹ️ 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".

@imjlk
imjlk merged commit 45fa891 into main Aug 10, 2026
6 checks passed
@imjlk
imjlk deleted the codex/fix-create-game-starter branch October 27, 2026 11:26
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