You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been chatting to Allen Helton about this, thought I'd add some additional context from a little bit of exploration I've done this morning, sorry if there's anything here you all already know :)
My working assumption is that the issue comes from using Tonic, well gRPC in general. Under the hood the way the Tonic client works isn't compatible with running 'in a browser', which is in essence what Wasm is. When you try and compile the code targetting WASM, you get compile errors related to Socket configuration.
There is a crate that supports generating a WASM compatible Tonic client and it looks like it is maintained. That said, I think the actual code changes would need to be in the client-protos library, as this is where all the Tonic client code is generated. I've had a quick look, but my knowledge kind of falls down at this point in terms of how the tonic builder works and if there would be a way to generate all the clients from Proto files in a WASM friendly way.
Hope that helps, @me if you have any follow up questions.
EDIT: Discovered that there is some work ongoing inside Tonic to that will help support this - hyperium/tonic#1594
A customer reported the following error when trying to use our SDK from cloudflare workers.
“socket2 does not support WASI・・・”
We would like to be supported on Cloudflare workers ideally we need to look into what we can do about this.
The text was updated successfully, but these errors were encountered: