Closed nazrincode closed 1 year ago
Are you using any kind of persistance?
What do you mean by persistance?
Did you set up something like apollo-cache-persist?
If you did not, restarting your app will always completely clear your cache. In that case you are probably not completely killing your app on iOS - have you tried rebooting your phone?
No I'm not using that.
By the way this is my option:
defaultOptions: { watchQuery: { fetchPolicy: 'no-cache', errorPolicy: 'ignore', }, query: { fetchPolicy: 'no-cache', errorPolicy: 'all', }, }
Oh, wait, I reread that - so this is not an issue with an error persisting over an app restart, but you getting a 403 error?
A 403 is sent by your server to your client - can you take a look at your server logs?
I can confirm that is nothing wrong on my server side. Keep getting networkError 403 code. This is really weird because:
For Android : Response 200. For iOS : Response 403.
403 is a code sent by your server. That usually cannot change on the way to the client, and the client does also not pull that out of thin air.
The 403 might be sent by the server for good reasons, because it is getting a different request from your Android clients vs. your iOS clients, but you would still see in the server logs that the server sent a 403, and why that 403 was sent.
The only alternative is that you have a load balancer or something that changes your status code to a 403, but that is highly unprobably, usually a load balancer would only change the status to a 5xx error code.
Hi @nazrincode 👋🏻 sorry you're dealing with issue, sounds frustrating. Unfortunately I don't think there's anything we can offer besides some general advice. Let us know if there's a way for us to reproduce this scenario and I'm sure we'd be able to figure it out. I'll echo Lenz's comments above RE: inspecting the server response, it's likely the source of this problem 🙏🏻
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. For general questions, we recommend using StackOverflow or our discord server.
Issue Description
Hi, I got this weird issue using this library in my React Native project.
Link to Reproduction
df
Reproduction Steps
These are the flows for both platform iOS and Android:
Android : Success Fetch iOS : Keep getting Network Error with status code 403.