-
Notifications
You must be signed in to change notification settings - Fork 4
Getting Cannot read properties of undefined (reading 'replace') error #9
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
Comments
Hey 👋 What node runtime are you using in your lambda? |
Node runtime: Node 18x
Since I am using RDS proxy, I cannot connect from my localhost, and thus cannot generate the non-bundled stack trace. I also tried the postgres Dialact that comes in kysely. It's also having problem connecting to the RDS proxy. and I found this github issue regarding same: brianc/node-postgres#2112 So I suspect it's something to do with the RDS proxy. but still, I could not find any solution. If you faced something similar, and could help me, I would greatly appreciate. ^_^ |
SST projects are notorious for having multiple kysely versions installed. I suspect this is your issue. SST core uses kysely 0.25.x afaik. You could switch to pnpm/yarn or find a way to deduplicate your kysely dependency in node_modules. This seems unrelated to this dialect. |
Thanks for your reply. I will check that. |
I am getting this error.
My setup is same as given in the readme example. I am using RDS proxy on AWS.
ERROR Uncaught Exception {"errorType":"TypeError","errorMessage":"Cannot read properties of undefined (reading 'replace')","stack":["TypeError: Cannot read properties of undefined (reading 'replace')"," at queryError (file:///var/task/packages/functions/src/my-lambda.mjs:807408:49)"," at errored (file:///var/task/packages/functions/src/my-lambda.mjs:807403:17)"," at Socket.error (file:///var/task/packages/functions/src/my-lambda.mjs:807395:5)"," at Socket.emit (node:events:517:28)"," at Socket.emit (node:domain:489:12)"," at emitErrorNT (node:internal/streams/destroy:151:8)"," at emitErrorCloseNT (node:internal/streams/destroy:116:3)"," at process.processTicksAndRejections (node:internal/process/task_queues:82:21)"]}
The text was updated successfully, but these errors were encountered: