Repository navigation
feat(cli): validate deployment runtimes and tool requirements - #1110
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 21104be00e
ℹ️ 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".
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
WalkthroughThis PR updates Cloudflare deployment generation, D1 setup, frontend templates, dependency wiring, environment typing, and CLI guidance for Effect-based Alchemy stack output. ChangesCloudflare Alchemy migration
Possibly related issues
Possibly related PRs
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🧹 Nitpick comments (1)
packages/template-generator/templates/packages/infra/alchemy.run.ts.hbs (1)
79-573: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚖️ Poor tradeoffConsider reducing duplication between self-backend and non-self-backend web worker sections.
The self-backend
webexport block (lines 79–331) and the non-self-backend inline web worker block (lines 345–561) share near-identicalStaticSite/Vitestructures withEffect.genwrappers, differing primarily in env var contents. This ~480-line span could benefit from a Handlebars partial or a shared env-var sub-template to reduce maintenance burden when adding frameworks or env vars.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: fe61af49-b6d0-497c-9fa4-4b021427f869
📒 Files selected for processing (19)
apps/cli/src/helpers/core/post-installation.tsapps/cli/test/addons.test.tsapps/cli/test/deployment.test.tspackages/template-generator/src/processors/alchemy-plugins.tspackages/template-generator/src/processors/deploy-deps.tspackages/template-generator/src/processors/env-vars.tspackages/template-generator/src/processors/infra-deps.tspackages/template-generator/src/processors/readme-generator.tspackages/template-generator/src/template-handlers/packages.tspackages/template-generator/src/templates.generated.tspackages/template-generator/src/utils/add-deps.tspackages/template-generator/templates/extras/env.d.ts.hbspackages/template-generator/templates/frontend/astro/astro.config.mjs.hbspackages/template-generator/templates/frontend/nuxt/nuxt.config.ts.hbspackages/template-generator/templates/frontend/react/react-router/vite.config.ts.hbspackages/template-generator/templates/frontend/svelte/svelte.config.js.hbspackages/template-generator/templates/packages/env/src/cloudflare-local.ts.hbspackages/template-generator/templates/packages/env/src/server.ts.hbspackages/template-generator/templates/packages/infra/alchemy.run.ts.hbs
💤 Files with no reviewable changes (3)
- packages/template-generator/templates/packages/env/src/cloudflare-local.ts.hbs
- packages/template-generator/src/processors/env-vars.ts
- packages/template-generator/src/template-handlers/packages.ts
Deep-review findings addressed (cb8a469)A second review pass (Codex, run locally) reported 4 P1 + 4 P2 findings. Each was verified empirically before acting: Confirmed and fixed:
Refuted with evidence:
Deferred as follow-ups: |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 50c00395-0eec-4933-8a7f-bf8fdce12abd
📒 Files selected for processing (8)
packages/template-generator/src/post-process/package-configs.tspackages/template-generator/src/processors/alchemy-plugins.tspackages/template-generator/src/processors/deploy-deps.tspackages/template-generator/src/processors/readme-generator.tspackages/template-generator/src/templates.generated.tspackages/template-generator/templates/frontend/nuxt/nuxt.config.ts.hbspackages/template-generator/templates/frontend/react/tanstack-start/vite.config.ts.hbspackages/template-generator/templates/packages/infra/alchemy.run.ts.hbs
🚧 Files skipped from review as they are similar to previous changes (2)
- packages/template-generator/templates/packages/infra/alchemy.run.ts.hbs
- packages/template-generator/src/templates.generated.ts
Second review round addressed (c469036)Verified each finding empirically again. Outcomes: Confirmed → fixed:
Refuted (again), now with a third live artifact: "StaticSite builds bake localhost:3000 into production." A fresh both-Cloudflare deploy of the current template inlined the real Deferred: Suite: 550 tests, 0 fail; lint clean; generator typecheck clean. |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
apps/cli/src/helpers/core/post-installation.ts (1)
626-633: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚖️ Poor tradeoffDuplicated
hasLocalD1logic across two files.The
hasLocalD1computation and framework list["next", "nuxt", "svelte", "astro"]is duplicated verbatim inpackages/template-generator/src/post-process/package-configs.ts:200-208. If the supported framework set changes, both locations must be updated in lockstep. Consider extracting this predicate into a shared utility (e.g., inpackages/typesor a shared helpers module) to keep a single source of truth.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 41081fec-310d-4a57-9cd3-aa7cbdd7d5b6
📒 Files selected for processing (9)
apps/cli/src/helpers/core/post-installation.tspackages/template-generator/src/post-process/package-configs.tspackages/template-generator/src/processors/alchemy-plugins.tspackages/template-generator/src/processors/deploy-deps.tspackages/template-generator/src/processors/readme-generator.tspackages/template-generator/src/templates.generated.tspackages/template-generator/templates/api/orpc/server/src/context.ts.hbspackages/template-generator/templates/frontend/nuxt/nuxt.config.ts.hbspackages/template-generator/templates/packages/infra/alchemy.run.ts.hbs
🚧 Files skipped from review as they are similar to previous changes (7)
- packages/template-generator/templates/frontend/nuxt/nuxt.config.ts.hbs
- packages/template-generator/src/post-process/package-configs.ts
- packages/template-generator/src/processors/readme-generator.ts
- packages/template-generator/src/processors/deploy-deps.ts
- packages/template-generator/templates/packages/infra/alchemy.run.ts.hbs
- packages/template-generator/src/processors/alchemy-plugins.ts
- packages/template-generator/src/templates.generated.ts
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: e76e0c93-04d7-4e02-99fd-184b759ce71d
📒 Files selected for processing (15)
apps/cli/src/helpers/core/post-installation.tsapps/cli/src/helpers/database-providers/d1-setup.tsapps/cli/src/utils/compatibility-rules.tsapps/cli/test/cloudflare-db-clients.test.tsapps/cli/test/database-setup.test.tsapps/cli/test/deployment.test.tsapps/cli/test/post-installation.test.tsapps/cli/test/vite-plus-generator.test.tspackages/template-generator/src/processors/alchemy-plugins.tspackages/template-generator/src/processors/workspace-deps.tspackages/template-generator/src/templates.generated.tspackages/template-generator/src/utils/add-deps.tspackages/template-generator/src/utils/generated-ignore-patterns.tspackages/template-generator/templates/backend/server/base/tsdown.config.ts.hbspackages/template-generator/templates/packages/infra/alchemy.run.ts.hbs
✅ Files skipped from review due to trivial changes (1)
- apps/cli/src/utils/compatibility-rules.ts
🚧 Files skipped from review as they are similar to previous changes (4)
- packages/template-generator/src/utils/add-deps.ts
- packages/template-generator/src/processors/alchemy-plugins.ts
- packages/template-generator/templates/packages/infra/alchemy.run.ts.hbs
- packages/template-generator/src/templates.generated.ts
Alchemy v2 / Astro follow-up status — 2026-07-13I re-audited the current PR head ( Important reconciliation: the Output tests are not contradictoryThe earlier three live deployments of this template were valid: the generated production bundle There is nevertheless a real beta.61 bug in raw upstream Upstream PR/release status
So the actual upstream wait is:
Newly confirmed Alchemy defects with no upstream PR yetThese are independent of Astro and remain present on current Alchemy main:
There is currently no issue/PR fixing either defect, so the existing upstream PRs are not the entire Astro: what works and what is still missingThe basic Astro SSR shape is sound: What Alchemy still does not consume is Astro's generated Wrangler/deploy contract:
There is no active Astro implementation PR for that contract. The general framework-adapter problem Better-T-Stack work that is ours, not upstream'sThe current PR still has a few independent follow-ups:
These should not be deferred behind Alchemy releases because they are generator correctness gaps. Verification evidence
Bottom line: keep |
Alchemy beta.64 refresh (
|
Progress update — 2026-07-25The beta.64 refresh is complete on Completed
Current PR state
Remaining upstream gates
The PR itself is ready from the template/repository side. The next cleanup is release-gated: after the relevant Alchemy fixes are published, bump the exact version and remove each workaround only after its focused generated-project and live-deploy test passes. |
|
Thanks for this pr. I'm following it up closely as I intend to migrate my current project from v1 to v1. It's using hono orpc and tanstack-start. |
Alchemy beta.66 evaluation and Cloudflare update (
|
Alchemy beta.67 upgrade verified and pushedUpdated in What changed
Release gates run
Remaining upstream work
No new actionable review comments were present; old comments were already addressed or evidence-backed false positives. |
|
Fresh full-template audit is complete and pushed through the stack. I regenerated 68 install-ready projects from the current CLI with Bun, npm, and pnpm. The matrix covers every combination affected by this stack: all changed Cloudflare framework paths, standalone Workers, D1, Neon, PlanetScale Postgres/MySQL, Prisma Postgres, Drizzle/Prisma, all supported Prisma deployment frameworks and mixed planes, every changed Sentry integration, SolidStart v2, Bun/Node runtime selection, Docker, Nx, and Vite+. Final result:
The audit caught and fixed two real generator defects:
No new workaround was added. Remaining compatibility code is limited to the documented upstream gates: The local inspection matrix is at |
a6c3d6e to
976eacd
Compare
976eacd to
0a0f9fb
Compare
0a0f9fb to
748774e
Compare
748774e to
ed609ef
Compare
ed609ef to
356acfc
Compare
356acfc to
e45956f
Compare
Fresh Cloudflare infrastructure verificationTested from projects generated by the current branch, using the released Alchemy beta.72 packages:
The live run exposed and this push fixes three DX issues:
Next.js reached a successful OpenNext production build, but this Cloudflare free account rejected the upload because the compressed Worker exceeds its 3 MiB plan limit. Partial resources were successfully destroyed. This is an account-plan limit, not a template or Alchemy failure. Verification after the fixes:
Commit: |
Summary
alchemy@2.0.0-beta.72and Effect/platform beta.107 versions with no override, provider patch, hoisting rule, or linker workaround.Stack
Layer 8 of 8. Previous: #1152.
This is the top of native GitHub stack #1150. Merge the stack together so every feature PR contributes its own release-note entry.
Verification
bun run checkbun run build:clinpx alchemy --helpandbunx alchemy --helpstart with beta.72 + Effect beta.107The remaining generated compatibility code is narrow and documented in the local matrix README: generic StaticSite memo invalidation, Alchemy's injected-Vite guard pending #1183, the registered React Router Worker entry, and explicit typed Astro bindings. There are no dependency overrides, patches, hoisted-linker requirements, git dependencies, custom Alchemy wrappers, manually resolved Outputs, duplicate database files, or synthetic SPA servers.
The only current npm metadata rough edge is Alchemy's exact optional Drizzle RC peer:
npm ls drizzle-ormreports it against the app's stable Drizzle, while install, typecheck, build, and Alchemy startup pass. The template intentionally does not change the application's ORM or package-manager layout to suppress that upstream metadata result.Stack created with GitHub Stacks CLI • Give Feedback 💬