Suddenly started getting these runtime errors :- `...
# help
a
Suddenly started getting these runtime errors :-
Copy code
Unhandled Promise Rejection     {"errorType":"Runtime.UnhandledPromiseRejection","errorMessage":"TypeError: Cannot read properties of undefined (reading 'ServerClient')","reason":"TypeError: Cannot read properties of undefined (reading 'ServerClient')","promise":{},"stack":["Runtime.UnhandledPromiseRejection: TypeError: Cannot read properties of undefined (reading 'ServerClient')","    at process.<anonymous> (file:///Users/ashish/work/planet-marathi/api-v2/node_modules/@serverless-stack/aws-lambda-ric/lib/index.js:34:23)","    at process.emit (node:events:526:28)","    at process.emit (node:domain:475:12)","    at emit (node:internal/process/promises:140:20)","    at processPromiseRejections (node:internal/process/promises:274:27)","    at processTicksAndRejections (node:internal/process/task_queues:97:32)"]}
Any ideas what could be going wrong? The
ServerClient
refers to a class in a npm module called
postmark
that I use to send emails. Here’s the reference to the lib - http://wildbit.github.io/postmark.js/index.html
f
Hey @Ashishkumar Pandey did this start happening after updating SST?
a
Yep, I’m sure this worked fine with 0.53.3. I didn’t check after upgrading to 0.63.0.
f
And which version r u getting this in?
a
I have tested in both 0.66.0 and 0.69.3, it breaks in both of them unfortunately.
j
@Ashishkumar Pandey just checking, are you still having this issue?
a
@Jay nope, removed the offending lib. 😂
j
Ah got it!