-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Description
Is there an existing issue for this?
- I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- I have reviewed the documentation https://docs.sentry.io/
- I am using the latest SDK release https://github.com/getsentry/sentry-javascript/releases
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/aws-serverless
SDK Version
10.39.0
Framework Version
NodeJS 24 on AWS Lambda
Link to Sentry event
https://basisbeeld.sentry.io/issues/20900435/
Reproduction Example/SDK Setup
We have a main instrument.mjs loading the dsn.
The code below should be enough to trigger the error (on AWS Lambda):
const handlerFn = async () => {
return [null];
}
const sentryOptions = { captureAllSettledReasons: true };
export const handler = Sentry.wrapHandler(() => handlerFn(), sentryOptions);
Steps to Reproduce
With captureAllSettledReasons set to true return an empty with anything that will fail the Object.prototype.hasOwnProperty.call(v, 'status') check (undefined/null).
Expected Result
That sentry does not crash our app ;)
Actual Result
Cannot convert undefined or null to object
Additional Context
This line triggers the check, which is good.
In this function an additional check should be made if v is actually an object, before doing object checks.
Priority
React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it.
Metadata
Metadata
Assignees
Labels
Projects
Status