-
Notifications
You must be signed in to change notification settings - Fork 82
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
CancelFn isn't cancelling the stream with Expo 52 #1363
Comments
@timostamm Can you please help me here? Maybe I'm just doing something wrong here. But it seems that after receiving a message, this will make the |
Hey @hollanderbart Can you share a reproducible example? We do have a test that checks for this case. |
Not yet. I can create one tomorrow. Is there a public stream call I can use? I think it's a race condition because after the first message has arrived, the cancel isn't working. |
Yes, you use this rpc hosted at
It indirectly checks this by validating the responses it is supposed to receive. We also pass the signal to |
Repo: https://github.com/hollanderbart/BusinessCards-Connect The logs that it print is:
|
Or is the need for a custom Transport necessary? Can the React Native example app please updated using the latest |
Hey Bart, for a very long time, React Native didn't implement I'm very happy that RN finally has If the CancelFn returned by the callback client doesn't abort the request in RN, this is a bug in the fetch implementation of RN / expo, since we continually run tests asserting that it does, on various web browsers and Node.js. Can you try to reproduce the problem with a minimal example that uses |
I've changed my repo to implement a simple httpbin stream. Also I've created an issue report on Expo here |
I'm going to go ahead and close this, but feel free to reopen if needed |
Describe the bug
When I've created a
createCallbackClient
callback client, and I created a stream, aCancelFn
will be returned. If I want to cancel this function, the stream isn't cancelled.To Reproduce
Environment (please complete the following information):
Connectrpc/connect in combination with React Native
The text was updated successfully, but these errors were encountered: