-
Notifications
You must be signed in to change notification settings - Fork 450
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
error in openapi3filter.RequestError: refresh token is missing #2699
Comments
Thanks for the report. That request should make no call to the /token endpoint though, so there must be something else going on. Would you mind providing a sample repository triggering the issue? You can also take a look at our comprehensive react example which doesn't seem to trigger this issue: code: https://github.com/nhost/nhost/tree/main/examples/react-apollo |
Thanks for your reply @dbarrosop. I tried to strip down my code to bare bones to isolate the issue and I think I found the cause of the problem. I was running my code locally in dev mode and I was already logged in as one of the users of my app. So, commenting out pretty much all the code from the root of my app and refreshing the browser page still produced the same error, as my user remained logged in. This made me thinking that it's got to be something to do with I wonder if the bug was introduced in the version of the "@nhost/react": "^3.4.2" that I'm using. In the example you provided (https://github.com/nhost/nhost/tree/main/examples/react-apollo) P.S. The example you provided still uses the |
It uses the latest one as it is rebuilt on every release.
The example I provided uses @nhost/react-apollo from the same repo.
As mentioned above, the example above, the reference documentation and our quickstart are all using that library. |
Describe the bug
When trying to use simple
useSignInEmailPassword
hook from the@nhost/react
lib in order to authenticate with email and password, I can see 4 requests to https://[my-domain].auth.eu-west-2.nhost.run/v1/token in my browser's dev tools network tab, with first 3 of them sending refreshToken as a payload and get back response 200, yet the last one doesn't have a refreshToken in its payload and returns the following error:"error": "error in openapi3filter.RequestError: request body has an error: doesn't match schema #/components/schemas/RefreshTokenRequest: Error at "/refreshToken": property "refreshToken" is missing"
Worth noting that a user gets authenticated fine.
To Reproduce
Steps to reproduce the behavior:
useSignInEmailPassword
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: