-
Notifications
You must be signed in to change notification settings - Fork 734
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
fix: toggle workers.dev
subdomains only when required
#836
Conversation
This fix - - passes the correct query param to check whether a workers.dev subdomain has already been published/enabled - thus enabling it only when it's not been enabled - it also disables it only when it's explicitly knows it's already been enabled The effect of this is that publishes are much faster.
🦋 Changeset detectedLatest commit: adf7a77 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
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.developers.workers.dev/runs/2213087294/npm-package-wrangler-836 You can reference the automatically updated head of this PR with: npm install --save-dev https://prerelease-registry.developers.workers.dev/prs/836/npm-package-wrangler-836 Or you can use npx https://prerelease-registry.developers.workers.dev/runs/2213087294/npm-package-wrangler-836 dev path/to/script.js |
workerUrl, | ||
{ | ||
method: "PUT", | ||
body: createWorkerUploadForm(worker), | ||
}, | ||
new URLSearchParams({ available_on_subdomain: "true" }) | ||
new URLSearchParams({ include_subdomain_availability: "true" }) |
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.
I can confirm that this is the correct parameter (by looking at the internal code). But it is worrying that this does not appear in our API docs, as far as I can tell.
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.
It's not a documented api, I found it on an internal wiki, I don't think it ever went public.
Hrmm GitHub is rate limiting right now, dunno why. I'll retry CI in a few minutes |
This fix -
The effect of this is that publishes are much faster.