-
Notifications
You must be signed in to change notification settings - Fork 716
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for named entrypoints #5215
Conversation
🦋 Changeset detectedLatest commit: d342bd6 The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
A wrangler prerelease is available for testing. You can install this latest build in your project with: npm install --save-dev https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/8545615151/npm-package-wrangler-5215 You can reference the automatically updated head of this PR with: npm install --save-dev https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/prs/5215/npm-package-wrangler-5215 Or you can use npx https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/8545615151/npm-package-wrangler-5215 dev path/to/script.js Additional artifacts:npx https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/8545615151/npm-package-create-cloudflare-5215 --no-auto-update npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/8545615151/npm-package-cloudflare-kv-asset-handler-5215 npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/8545615151/npm-package-miniflare-5215 npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/8545615151/npm-package-cloudflare-pages-shared-5215 npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/8545615151/npm-package-cloudflare-vitest-pool-workers-5215 Note that these links will no longer work once the GitHub Actions artifact expires.
Please ensure constraints are pinned, and |
4961cfc
to
6a5ec8e
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #5215 +/- ##
==========================================
+ Coverage 72.12% 72.18% +0.06%
==========================================
Files 331 331
Lines 17123 17175 +52
Branches 4371 4386 +15
==========================================
+ Hits 12350 12398 +48
- Misses 4773 4777 +4
|
6a5ec8e
to
bf0e728
Compare
0084213
to
5350fe0
Compare
@@ -1,9 +1,24 @@ | |||
// TODO(soon): remove once https://github.com/cloudflare/workerd/pull/1870 lands |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eagle has landed 🦅
Just need to publish to npm, and then we should be good to go. Looks like there was a problem with that latest run though: https://github.com/cloudflare/workerd/actions/runs/8438068332
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are we going to remove this file before merging?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the reminder. Yes, I'll do that now.
Update error messages
Okay, once these pass, I'm merging and will follow up with another PR to bump to the latest workerd version 🚀 |
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [wrangler](https://togithub.com/cloudflare/workers-sdk) ([source](https://togithub.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler)) | [`3.51.2` -> `3.52.0`](https://renovatebot.com/diffs/npm/wrangler/3.51.2/3.52.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/wrangler/3.52.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/wrangler/3.52.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/wrangler/3.51.2/3.52.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/wrangler/3.51.2/3.52.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>cloudflare/workers-sdk (wrangler)</summary> ### [`v3.52.0`](https://togithub.com/cloudflare/workers-sdk/blob/HEAD/packages/wrangler/CHANGELOG.md#3520) [Compare Source](https://togithub.com/cloudflare/workers-sdk/compare/[email protected]@3.52.0) ##### Minor Changes - [#​5666](https://togithub.com/cloudflare/workers-sdk/pull/5666) [`81d9615`](https://togithub.com/cloudflare/workers-sdk/commit/81d961582da2db2b020305c63a9f1f1573ff873d) Thanks [@​CarmenPopoviciu](https://togithub.com/CarmenPopoviciu)! - fix: Fix Pages config validation around Durable Objects Today Pages cannot deploy Durable Objects itself. For this reason it is mandatory that when declaring Durable Objects bindings in the config file, the `script_name` is specified. We are currently not failing validation if `script_name` is not specified but we should. These changes fix that. ##### Patch Changes - [#​5610](https://togithub.com/cloudflare/workers-sdk/pull/5610) [`24840f6`](https://togithub.com/cloudflare/workers-sdk/commit/24840f67b6495a664f5463697aa49fa9478435b9) Thanks [@​SuperchupuDev](https://togithub.com/SuperchupuDev)! - Mark `ts-json-schema-generator` as a dev dependency - [#​5669](https://togithub.com/cloudflare/workers-sdk/pull/5669) [`a7e36d5`](https://togithub.com/cloudflare/workers-sdk/commit/a7e36d503f442a8225ffdedef30b569a8a396663) Thanks [@​dario-piotrowicz](https://togithub.com/dario-piotrowicz)! - fix: fix broken Durable Object local proxying (when no `cf` property is present) A regression was introduced in wrangler 3.46.0 ([https://github.com/cloudflare/workers-sdk/pull/5215](https://togithub.com/cloudflare/workers-sdk/pull/5215)) which made it so that missing `Request#cf` properties are serialized as `"undefined"`, this in turn throws a syntax parse error when such values are parsed via `JSON.parse` breaking the communication with Durable Object local proxies. Fix such issue by serializing missing `Request#cf` properties as `"{}"` instead. - [#​5616](https://togithub.com/cloudflare/workers-sdk/pull/5616) [`c6312b5`](https://togithub.com/cloudflare/workers-sdk/commit/c6312b5017279b31ce99c761e2063973f7d948bf) Thanks [@​webbertakken](https://togithub.com/webbertakken)! - fix: broken link to durable object migrations docs - [#​5482](https://togithub.com/cloudflare/workers-sdk/pull/5482) [`1b7739e`](https://togithub.com/cloudflare/workers-sdk/commit/1b7739e0af99860aa063f01c0a6e7712ac072fdb) Thanks [@​DaniFoldi](https://togithub.com/DaniFoldi)! - docs: show new Discord url everywhere for consistency. The old URL still works, but https://discord.cloudflare.com is preferred. - Updated dependencies \[[`3a0d735`](https://togithub.com/cloudflare/workers-sdk/commit/3a0d7356bd8bc6fe614a3ef3f9c1278659555568), [`1b7739e`](https://togithub.com/cloudflare/workers-sdk/commit/1b7739e0af99860aa063f01c0a6e7712ac072fdb)]: - [email protected] - [@​cloudflare/kv-asset-handler](https://togithub.com/cloudflare/kv-asset-handler)[@​0](https://togithub.com/0).3.2 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/Johannes-Andersen/Johannes). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zMTMuMSIsInVwZGF0ZWRJblZlciI6IjM3LjMxMy4xIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJ0eXBlL2RlcGVuZGVuY2llcyJdfQ==--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
LDW exemption: CR-849919
What this PR solves / how to test
(updated by @mrbbot)
This PR adds support for named entrypoints to
wrangler deploy
andwrangler (pages) dev
. This also enables support for JS RPC over multiplewrangler dev
sessions.Service bindings to other
wrangler dev
sessions are now implemented withworkerd
-nativeexternal
service bindings instead of middleware. This is required to use Cap'n Proto over HTTP for JSRPC. This middleware was the last middleware that wrapped theenv
object. Code for wrappingenv
has been removed from the middleware loader. Implementing this forWorkerEntrypoint
s would've required us to look for named exports and applyenv
wrapping to all of these.Author has addressed the following