Skip to content

chore: commit generated worker types in flue-review and playground - #2392

Merged
ascorbic merged 4 commits into
mainfrom
chore/commit-worker-types
Aug 12, 2026
Merged

chore: commit generated worker types in flue-review and playground#2392
ascorbic merged 4 commits into
mainfrom
chore/commit-worker-types

Conversation

@ascorbic

@ascorbic ascorbic commented Aug 9, 2026

Copy link
Copy Markdown
Collaborator

What does this PR do?

Commits the generated worker-configuration.d.ts in infra/flue-review and demos/playground, and removes the .gitignore entries that hid it. Every other worker package in the repo commits this file (both bots aside, nine packages do); these two — plus infra/emdash-bot, fixed on the bot next-gen stack — were the only ones ignoring it, which left CI's type-aware lint and fresh checkouts running without the workers ambient types. That is what caused the RequestInfo-as-any lint failure on #2382 and the missing-Env typecheck errors in fresh worktrees.

The generated files contain binding shapes and secret names only, no values.

Closes #

Type of change

  • Bug fix
  • Feature (requires maintainer-approved Discussion)
  • Refactor (no behavior change)
  • Translation
  • Documentation
  • Performance improvement
  • Tests
  • Chore (dependencies, CI, tooling)

Checklist

  • I have read CONTRIBUTING.md
  • pnpm typecheck passes
  • pnpm lint passes
  • pnpm test passes (or targeted tests for my change)
  • pnpm format has been run
  • I have added/updated tests for my changes (if applicable)
  • User-visible strings in the admin UI are wrapped for translation (if applicable). Do not include messages.po changes except in translation PRs — a workflow extracts catalogs on merge to main.
  • I have added a changeset (if this PR changes a published package)
  • New features link to an approved Discussion: https://github.com/emdash-cms/emdash/discussions/...

Tests, changeset, and i18n are n/a: the change adds generated type declarations and removes two .gitignore lines in private packages — no runtime behavior, no published package. Typecheck n/a for the same reason (the files are inputs to typechecking, not subjects of it); pnpm lint verified on the touched packages.

AI-generated code disclosure

  • This PR includes AI-generated code — model/tool: Claude Fable 5 (Claude Code) — the committed type files are wrangler types output.

Screenshots / test output


Try this PR

Open a fresh playground →

A full working EmDash site, deployed from this branch. Each visit gets its own session-scoped sandbox: no login needed and no shared state. Try the admin, edit content, hit the public site.

Tracks chore/commit-worker-types. Updated automatically when the playground redeploys.

Copilot AI lite review requested due to automatic review settings August 9, 2026 08:34
@changeset-bot

changeset-bot Bot commented Aug 9, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 0fb3c04

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Aug 9, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
emdash-demo-cache 0fb3c04 Aug 12 2026, 12:04 PM

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Aug 9, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
emdash-playground 0fb3c04 Aug 12 2026, 12:03 PM

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Aug 9, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
emdash-demo-do 0fb3c04 Aug 12 2026, 12:04 PM

@github-actions

github-actions Bot commented Aug 9, 2026

Copy link
Copy Markdown
Contributor

Scope check

This PR changes 28,986 lines across 4 files. Large PRs are harder to review and more likely to be closed without review.

If this scope is intentional, no action needed. A maintainer will review it. If not, please consider splitting this into smaller PRs.

See CONTRIBUTING.md for contribution guidelines.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Warning

Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.

Removes .gitignore rules that previously excluded worker-configuration.d.ts in two worker packages, with the intent of committing the generated Wrangler type declarations so fresh checkouts and CI have the correct ambient worker types.

Changes:

  • Stop ignoring worker-configuration.d.ts in infra/flue-review
  • Stop ignoring worker-configuration.d.ts in demos/playground

Reviewed changes

Copilot reviewed 2 out of 4 changed files in this pull request and generated 2 comments.

File Description
infra/flue-review/.gitignore Removes ignore rule so generated worker types can be committed/tracked
demos/playground/.gitignore Removes ignore rule so generated worker types can be committed/tracked

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines 2 to 5
.wrangler/
.flue-vite/
.flue-vite*.wrangler.jsonc
worker-configuration.d.ts
.dev.vars
Comment on lines 2 to 4
dist/
.astro/
.wrangler/
@github-actions github-actions Bot added the review/awaiting-author Reviewed; waiting on the author to respond label Aug 9, 2026
@pkg-pr-new

pkg-pr-new Bot commented Aug 9, 2026

Copy link
Copy Markdown

Open in StackBlitz

@emdash-cms/admin

npm i https://pkg.pr.new/@emdash-cms/admin@2392

@emdash-cms/auth

npm i https://pkg.pr.new/@emdash-cms/auth@2392

@emdash-cms/auth-atproto

npm i https://pkg.pr.new/@emdash-cms/auth-atproto@2392

@emdash-cms/blocks

npm i https://pkg.pr.new/@emdash-cms/blocks@2392

@emdash-cms/cloudflare

npm i https://pkg.pr.new/@emdash-cms/cloudflare@2392

@emdash-cms/contentful-to-portable-text

npm i https://pkg.pr.new/@emdash-cms/contentful-to-portable-text@2392

emdash

npm i https://pkg.pr.new/emdash@2392

create-emdash

npm i https://pkg.pr.new/create-emdash@2392

@emdash-cms/gutenberg-to-portable-text

npm i https://pkg.pr.new/@emdash-cms/gutenberg-to-portable-text@2392

@emdash-cms/plugin-cli

npm i https://pkg.pr.new/@emdash-cms/plugin-cli@2392

@emdash-cms/plugin-types

npm i https://pkg.pr.new/@emdash-cms/plugin-types@2392

@emdash-cms/registry-client

npm i https://pkg.pr.new/@emdash-cms/registry-client@2392

@emdash-cms/registry-lexicons

npm i https://pkg.pr.new/@emdash-cms/registry-lexicons@2392

@emdash-cms/registry-verification

npm i https://pkg.pr.new/@emdash-cms/registry-verification@2392

@emdash-cms/sandbox-workerd

npm i https://pkg.pr.new/@emdash-cms/sandbox-workerd@2392

@emdash-cms/x402

npm i https://pkg.pr.new/@emdash-cms/x402@2392

@emdash-cms/plugin-ai-moderation

npm i https://pkg.pr.new/@emdash-cms/plugin-ai-moderation@2392

@emdash-cms/plugin-atproto

npm i https://pkg.pr.new/@emdash-cms/plugin-atproto@2392

@emdash-cms/plugin-audit-log

npm i https://pkg.pr.new/@emdash-cms/plugin-audit-log@2392

@emdash-cms/plugin-color

npm i https://pkg.pr.new/@emdash-cms/plugin-color@2392

@emdash-cms/plugin-embeds

npm i https://pkg.pr.new/@emdash-cms/plugin-embeds@2392

@emdash-cms/plugin-field-kit

npm i https://pkg.pr.new/@emdash-cms/plugin-field-kit@2392

@emdash-cms/plugin-forms

npm i https://pkg.pr.new/@emdash-cms/plugin-forms@2392

@emdash-cms/plugin-webhook-notifier

npm i https://pkg.pr.new/@emdash-cms/plugin-webhook-notifier@2392

commit: 0fb3c04

@ascorbic ascorbic added the bot:review Trigger an emdashbot code review on this PR label Aug 9, 2026
@emdashbot emdashbot Bot removed the bot:review Trigger an emdashbot code review on this PR label Aug 9, 2026
@ascorbic ascorbic added the bot:review Trigger an emdashbot code review on this PR label Aug 9, 2026

@emdashbot emdashbot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Approach: this is the right change. EmDash already commits worker-configuration.d.ts in nine other worker packages, and gitignoring it meant CI type-aware lint and fresh worktrees lacked the ambient Env/runtime declarations. Committing the generated files for demos/playground and infra/flue-review aligns them with the rest of the repo and addresses the missing-Env/RequestInfo-as-any errors described in the PR.

I inspected the generated files, the .gitignore removals, the tsconfig.json references, and sibling worker-package conventions. Both files contain only binding shapes and secret/variable names — no secret values are leaked (the GITHUB_APP_ID/GITHUB_APP_INSTALLATION_ID values in the flue-review file are public Wrangler vars explicitly documented as non-secret in wrangler.jsonc). I also verified that .oxfmtrc.json already ignores worker-configuration.d.ts, so format no-ops on them.

Headline conclusion: one real gap. infra/flue-review/tsconfig.json already references the new file in its include, but demos/playground/tsconfig.json does not. AGENTS.md explicitly instructs: "Reference it in tsconfig.json's include", and the sibling Astro/Cloudflare demos (demos/cloudflare, demos/preview) both include it. Until demos/playground does the same, astro check will not load the ambient Env types, so the committed file does not fully solve the stated problem in that package.


Findings

  • [needs fixing] demos/playground/tsconfig.json:6

    This include list omits the newly committed worker-configuration.d.ts. AGENTS.md says to "Reference it in tsconfig.json's include" when generating this file, and the sibling Astro/Cloudflare demos (demos/cloudflare/tsconfig.json, demos/preview/tsconfig.json) both include it. Without adding it to the TypeScript project, astro check in this package will not load the ambient Env and runtime types, so committing the file does not actually fix the missing-Env/type-aware lint errors this PR targets.

    	"include": ["src", ".astro/types.d.ts", "emdash-env.d.ts", "worker-configuration.d.ts"]
    

@emdashbot emdashbot Bot removed the bot:review Trigger an emdashbot code review on this PR label Aug 9, 2026
@github-actions github-actions Bot added review/needs-rereview Author pushed changes since the last review and removed review/awaiting-author Reviewed; waiting on the author to respond labels Aug 12, 2026
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Aug 12, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
docs d816a5c Aug 12 2026, 11:39 AM

@ascorbic
ascorbic merged commit f4a33e6 into main Aug 12, 2026
46 checks passed
@ascorbic
ascorbic deleted the chore/commit-worker-types branch August 12, 2026 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: signed review/needs-rereview Author pushed changes since the last review size/XL

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants