Skip to content
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

Don't immediately exit on Pages Functions compilation error #671

Merged

Conversation

GregBrimble
Copy link
Member

Fixes #543

Previously, we'd exit the wrangler pages dev process if we couldn't immediately compile a Worker from the functions directory. We now log the error, but don't exit the process. This means that proxy processes can be cleaned up cleanly on SIGINT and SIGTERM, and it matches the behavior of if a compilation error is introduced once already running (we don't exit then either).

@GregBrimble GregBrimble added bug pages Relating to Pages labels Mar 22, 2022
@changeset-bot
Copy link

changeset-bot bot commented Mar 22, 2022

🦋 Changeset detected

Latest commit: 3895828

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
wrangler Patch

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

@github-actions
Copy link
Contributor

github-actions bot commented Mar 22, 2022

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/2024258092/npm-package-wrangler-671

You can reference the automatically updated head of this PR with:

npm install --save-dev https://prerelease-registry.developers.workers.dev/prs/671/npm-package-wrangler-671

Or you can use npx with this latest build directly:

npx https://prerelease-registry.developers.workers.dev/runs/2024258092/npm-package-wrangler-671 dev path/to/script.js

Co-authored-by: Pete Bacon Darwin <pete@bacondarwin.com>
@GregBrimble GregBrimble merged commit ef0aaad into main Mar 22, 2022
@GregBrimble GregBrimble deleted the dont-immediately-exit-on-pages-functions-compilation-error branch March 22, 2022 18:59
@github-actions github-actions bot mentioned this pull request Mar 22, 2022
mrbbot added a commit that referenced this pull request Oct 31, 2023
There are cases where mutating the URL returned from
`Miniflare#ready` may be desirable, e.g. changing the protocol to
`ws:` and using the `ws` module to establish a WebSocket connection.
Previously, doing this would break Miniflare's `dispatchFetch`, as
the returned URL was Miniflare's own internal reference. This change
makes sure we return a copy.
mrbbot added a commit that referenced this pull request Nov 1, 2023
There are cases where mutating the URL returned from
`Miniflare#ready` may be desirable, e.g. changing the protocol to
`ws:` and using the `ws` module to establish a WebSocket connection.
Previously, doing this would break Miniflare's `dispatchFetch`, as
the returned URL was Miniflare's own internal reference. This change
makes sure we return a copy.
mrbbot added a commit that referenced this pull request Nov 1, 2023
There are cases where mutating the URL returned from
`Miniflare#ready` may be desirable, e.g. changing the protocol to
`ws:` and using the `ws` module to establish a WebSocket connection.
Previously, doing this would break Miniflare's `dispatchFetch`, as
the returned URL was Miniflare's own internal reference. This change
makes sure we return a copy.
mrbbot added a commit that referenced this pull request Nov 1, 2023
There are cases where mutating the URL returned from
`Miniflare#ready` may be desirable, e.g. changing the protocol to
`ws:` and using the `ws` module to establish a WebSocket connection.
Previously, doing this would break Miniflare's `dispatchFetch`, as
the returned URL was Miniflare's own internal reference. This change
makes sure we return a copy.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pages Relating to Pages
Projects
None yet
Development

Successfully merging this pull request may close these issues.

🐛 BUG: wrangler@alpha should SIGTERM react-scripts on error
2 participants