-
Notifications
You must be signed in to change notification settings - Fork 778
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
validate binding names don't conflict #665
Conversation
🦋 Changeset detectedLatest commit: fdcbf3e 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/2034567542/npm-package-wrangler-665 You can reference the automatically updated head of this PR with: npm install --save-dev https://prerelease-registry.developers.workers.dev/prs/665/npm-package-wrangler-665 Or you can use npx https://prerelease-registry.developers.workers.dev/runs/2034567542/npm-package-wrangler-665 dev path/to/script.js |
631289c
to
0b55698
Compare
So...a bunch of tests started failing after I rebased. Turns out, we maybe can't trust the inputs to `validateBindingsHaveUniqueNames` to be valid since we don't actually _throw_ until we've performed every config validation. So that means by the time we get to `validateBindingsHaveUniqueNames`, we might have some invalid stuff in the `Config` and we can't really trust the types. :( So I've just gone back to using `getBindingNames` to get the binding names, since it does all the null & type checking necessary to get the binding names out from a binding.
e8d6487
to
852ad20
Compare
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.
Looks great!
We talked offline and there are some NITs that can be updated.
Approving in theory :-D
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.
Smashing!
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.
Oh one tiny NIT.
Co-authored-by: Pete Bacon Darwin <pete@bacondarwin.com>
closes #658