-
Notifications
You must be signed in to change notification settings - Fork 925
fix experimental remoteBindings flag not being properly propagated in getPlatformProxy
#9840
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 experimental remoteBindings flag not being properly propagated in getPlatformProxy
#9840
Conversation
🦋 Changeset detectedLatest commit: 2a0c7dd The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 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 |
9559022
to
f98c112
Compare
create-cloudflare
@cloudflare/kv-asset-handler
miniflare
@cloudflare/pages-shared
@cloudflare/unenv-preset
@cloudflare/vite-plugin
@cloudflare/vitest-pool-workers
@cloudflare/workers-editor-shared
wrangler
commit: |
… `getPlatformProxy`
f98c112
to
c7b5c9c
Compare
.changeset/huge-lies-lay.md
Outdated
|
||
fix experimental remoteBindings flag not being properly propagated in `getPlatformProxy` | ||
|
||
The changes here address the fact that experimental remoteBindings flag that user can set in their `getPlatformProxy` call is currently not being properly propagated, causing most of the bindings not to actually be treated as remote ones |
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.
causing most of the bindings
is there a list of bingings impacted instead of "most" ?
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.
Looking at the tests it looks like the only diff is KV?
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.
causing most of the bindings
is there a list of bingings impacted instead of "most" ?
Everything that support "experimental_remote": true
as I've experienced. Looking forward to this PR merge to resolve the issue I am having now.
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.
causing most of the bindings
is there a list of bingings impacted instead of "most" ?
"most" basically means all the bindings besides service ones, those worked before my changes (because of this erroneous line: https://github.com/cloudflare/workers-sdk/pull/9840/files#diff-564e7822c281c216ba6926ff5334b704657d6c80483b42f46c8de51ef1f1d5ccL209)
I'll clarify this in the changeset 👍
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.
causing most of the bindings
is there a list of bingings impacted instead of "most" ?
Everything that support
"experimental_remote": true
as I've experienced. Looking forward to this PR merge to resolve the issue I am having now.
I'm sorry to have inconvenienced you 😓
If you hit these sort of issues please feel always free to open issues in the repository so that we can help out 🙂
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.
causing most of the bindings
is there a list of bingings impacted instead of "most" ?
Everything that support
"experimental_remote": true
as I've experienced. Looking forward to this PR merge to resolve the issue I am having now.I'm sorry to have inconvenienced you 😓
If you hit these sort of issues please feel always free to open issues in the repository so that we can help out 🙂
No worries, I initially thought the issue was with @astro/cloudflare
package, but someone from astro community guide me to here.
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.
@vicb I've updated the changeset hopefully it is more clear now
Regarding the tests indeed I've only added a test for KV as I think that it'd be very impractical to test all the possible bindings here, one should hopefully be enough to give us confidence that the flag is being correctly propagated, let me know if you disagree
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!
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 see 2 more bugs, think it's related to this getPlatformProxy
preview_database_id
is not being picked on dev runs ie, when using say@astro/cloudflare
adapter and runningastro dev
environment
field is not properly propagated, ie passing that field has no effect, but if wrong value is passed ie, not available inwrangler.jsonc
an error is thrown.
also these works fine when running wrangler from CLI ie, wrangler dev
so the issue is not with wrangler CLI.
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.
Hi @shafkathullah, thanks for letting me know
Could you open 2 bug issues for these?
(If you could also share a minimal reproduction (which only uses getPlatformProxy
) that would be great)
The changes here address the fact that experimental remoteBindings flag that user can set in their
getPlatformProxy
call is currently not being properly propagated, causing most of the bindings not to actually be treated as remote ones