-
Notifications
You must be signed in to change notification settings - Fork 113
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: delete request body from server adapter #30
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
40f4a1d
to
917af17
Compare
34d5645
to
e7dcf70
Compare
Hey khuezy, This issue is affecting me as well. I would love to use next-auth with open-next. How can I help? |
I would like to add I am getting a I am deploying with node 18.13.0, next-auth 4.18.6, sst 2.0.0-rc.41, and next 13.1.3 My middleware.ts code looks like this: export { default } from "next-auth/middleware" // require authentication
export const config = { matcher: ["/:path*"] } // all pages |
Another person on another ticket was experiencing the same crypto error as you... |
If memory serves me right, middleware functions run in a slimmed down version of node called 'edge runtime' https://nextjs.org/docs/api-reference/edge-runtime Could be relevant |
As long as your |
Are you doing |
Yes. I am doing I am not exporting |
Do |
Doing that now. @khuezy That should fix the crypto issue? |
Another person had the same issue and resolved it using |
baec834
to
882ec5e
Compare
I tried running the next-auth checks in My code works on Vercel, but not with SST. The client does not redirect to Cognito as expected. Can provide a code example and versions if necessary. |
Did you monkeypatch the changes in this PR before deploying? |
Merging into master. I reverted the |
You don't know what I went through tracking this problem down in cdk-nextjs lol |
This PR fixes some issues:
Nextjs doesn't parse the body if it already exists on the request object: https://github.com/vercel/next.js/blob/canary/packages/next/src/server/api-utils/node.ts#L474
If a header has a space it in, the custom header ends up w/
null
fieldscompress: false
has been fixed in the latest nextjs version.EDIT: Do not merge yet