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
Describe the bug
Running an app and hosting in Vercel (using vercel-adapter) when data is posted to an endpoint containing non-empty body, the req object contains body set to undefined.
Can't reproduce this locally.
Running npm run dev works as expected.
Running npm run build && npm run start works as expected.
Running vercel dev works as expected.
One thing I've noticed is that the req payload in this @svelkit/kit version should already return both body and rawBody but somehow the code deployed to Vercel doesn't return rawBody.
Severity
How severe an issue is this bug to you? Is this annoying, blocking some users, blocking an upgrade or blocking your usage of SvelteKit entirely?
Note: the more honest and specific you are here the more we will take you seriously.
Non-blocking and I'm aware this tool is a WIP 😊
Please let me know if there's any other detail need and/or anything I can help with.
Additional context
Add any other context about the problem here.
Describe the bug
Running an app and hosting in Vercel (using vercel-adapter) when data is posted to an endpoint containing non-empty body, the
req
object contains body set toundefined
.Can't reproduce this locally.
npm run dev
works as expected.npm run build && npm run start
works as expected.vercel dev
works as expected.One thing I've noticed is that the req payload in this
@svelkit/kit
version should already return bothbody
andrawBody
but somehow the code deployed to Vercel doesn't returnrawBody
.Running latest adapter-vercel:
Logs
To Reproduce
Sample project - https://github.com/ivoreis/svelte-vercel-body
Information about your SvelteKit Installation:
Diagnostics
$ npx envinfo --system --npmPackages svelte,@sveltejs/kit,vite --binaries --browser
npx: installed 1 in 1.186s
System:
OS: macOS 11.2.3
CPU: (16) x64 Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz
Memory: 292.50 MB / 32.00 GB
Shell: 5.8 - /bin/zsh
Binaries:
Node: 14.15.3 - /usr/local/bin/node
Yarn: 1.22.4 - ~/.yarn/bin/yarn
npm: 6.14.9 - /usr/local/bin/npm
npmPackages:
@sveltejs/kit: next => 1.0.0-next.84
svelte: ^3.29.0 => 3.37.0
vite: ^2.1.0 => 2.2.1
Browser: Chrome, Safari, Edge, CURL
Severity
How severe an issue is this bug to you? Is this annoying, blocking some users, blocking an upgrade or blocking your usage of SvelteKit entirely?
Note: the more honest and specific you are here the more we will take you seriously.
Non-blocking and I'm aware this tool is a WIP 😊
Please let me know if there's any other detail need and/or anything I can help with.
Additional context
Add any other context about the problem here.
@Rich-Harris Do you think body (https://github.com/sveltejs/kit/blob/master/packages/adapter-vercel/files/entry.js#L15) should be rawBody instead?
Following the code I see https://github.com/sveltejs/kit/blob/master/packages/kit/src/runtime/server/parse_body/index.js#L5-L6 being used by SSR (https://github.com/sveltejs/kit/blob/master/packages/kit/src/runtime/server/index.js#L24) but I'm not familiar with the code to say for certain.
The text was updated successfully, but these errors were encountered: