Refactor#13845
Conversation
|
There was a problem hiding this comment.
I'm Bonk, and I've done a quick review of your PR.
This refactoring extracts shared deploy/versions-upload logic into shared.ts, moves autoconfig and open-next delegation into autoconfig.ts, and inlines the core deploy logic from deploy() into deployWorker() inside index.ts.
Issues found (ranked by severity)
-
Duplicate
describe("legacy")block in test file — lines 1132-1141 are an incomplete copy of the block that starts at line 1142. This will cause a parse/syntax error or malformed test structure. -
D1 binding special error handler removed — The old
deploy()function had a special case that caught API error 10021 with the specific D1 binding message and re-threw a user-friendly error. That handler was deleted from the newdeployWorker()inindex.ts(compare with the old code around thecatchblock). The source-mapping logic was kept, but the D1 guard was dropped. -
telemetryMessage: trueused for missing worker name — Perpackages/wrangler/AGENTS.md,telemetryMessage: truesends the user-facing message as the telemetry label and is discouraged when a stable static label is available. The old deploy and versions-upload paths had distinct stable labels (deploy command missing worker name/versions upload missing worker name).
create-cloudflare
@cloudflare/kv-asset-handler
miniflare
@cloudflare/pages-shared
@cloudflare/unenv-preset
@cloudflare/vite-plugin
@cloudflare/vitest-pool-workers
@cloudflare/workers-editor-shared
@cloudflare/workers-utils
wrangler
commit: |
|
Review posted successfully on PR #13845. Here's a summary of what I found:
|
37c40b4 to
e736431
Compare
|
✅ All changesets look good |
Fixes #[insert GH or internal issue link(s)].
Describe your change...
A picture of a cute animal (not mandatory, but encouraged)