edgedb-js
edgedb-js copied to clipboard
Auth-core throws weird errors when used with edgedb deploys on my own server
Describe the bug A clear and concise description of what the bug is.
Authentication failed: InvalidDataError: Missing query parameter: code
at decodeError (D:\...\node_modules\@edgedb\auth-core\dist\utils.js:117:16)
at requestGET (D:\...\node_modules\@edgedb\auth-core\dist\utils.js:47:19)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async GET (D:/.../node_modules/edge-auth-solid-start/src/server/index.ts:293:27)
at async eval (D:/.../node_modules/@solidjs/start/dist/server/handler.js:38:23)
at async _callHandler (file:///D:/.../node_modules/h3/dist/index.mjs:1821:16)
at async _callHandler (file:///D:/.../node_modules/h3/dist/index.mjs:1821:16)
at async file:///D:/.../node_modules/h3/dist/index.mjs:1962:19
at async Object.callAsync (file:///D:/.../node_modules/unctx/dist/index.mjs:72:16)
at async Server.toNodeHandle (file:///D:/.../node_modules/h3/dist/index.mjs:2249:7)
Reproduction
Include the code that is causing the error:
// code here
Expected behavior A clear and concise description of what you expected to happen. If applicable, add screenshots to help explain your problem.
Versions (please complete the following information):
- OS: Windows 11 & Ubuntu 24.04 LTS
- EdgeDB version (e.g.
2.0): 5.6+0d677a5 - EdgeDB CLI version (e.g.
2.0): edgedb-jsversion (e.g.0.20.10;): 1.5.4- Node/Deno version:
Additional context Add any other context about the problem here.
Hmmm, I can't think of what might be going on here based on the code you've provided in your screenshot. Do you mind linking to more of the code, and any details about the runtime (node, deno, bun, something else?)? Maybe there is a weird binding issue with this.core, or maybe some strange runtime garbage collection issue where the valid is present at call time, but somehow isn't getting closed over correctly? This seems far fetched, but not entirely impossible.
node version: v20.15.0
It happened here:
https://github.com/Huliiiiii/edgedb-js/blob/438101f371c09d9f22a281b636882dd4d9cf6568/packages/auth-solid-start/src/server/index.ts#L417-L424