-
Notifications
You must be signed in to change notification settings - Fork 590
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
Application stack trace being swallowed up #1287
Comments
Hi @Bene-Graham Thank you for reporting this. This is issue usually caused be async function throwing error inside a callback. I will need to take a closer look at it. |
A few notes: Overly transpiling isn't helping, expanding every async/await frame into a set of Returning a promise breaks the async stack:
At least in 7.3, when async stack traces were enabled, only |
Thank you for the insights. We have targeted all the Node.js packages to ES2018 in #1572. Here's how the stack trace will look like now: NoSuchKey: NoSuchKey
at deserializeAws_restXmlGetObjectCommandError (Path/to/@aws-sdk/client-s3/dist/cjs/protocols/Aws_restXml.js:5311:41)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async Path/to/@aws-sdk/middleware-serde/dist/cjs/deserializerMiddleware.js:12:20
at async Path/to/@aws-sdk/middleware-signing/dist/cjs/middleware.js:12:24
at async StandardRetryStrategy.retry (Path/to/@aws-sdk/middleware-retry/dist/cjs/defaultStrategy.js:55:46)
at async Path/to/@aws-sdk/middleware-logger/dist/cjs/loggerMiddleware.js:6:22
at async Path/to/test.js:29:18 {
name: 'NoSuchKey',
'$fault': 'client',
'$metadata': {
httpStatusCode: 404,
httpHeaders: {
'x-amz-request-id': '',
'x-amz-id-2': '',
'content-type': 'application/xml',
'transfer-encoding': 'chunked',
date: '',
server: 'AmazonS3'
},
requestId: undefined,
attempts: 1,
totalRetryDelay: 0
}
} This fix will be released very soon. |
Look forward to trying it out when the next package release happens 😄 |
Hi @Bene-Graham, the new version is available now. Please try the newest version |
That looks a lot better. Thank You. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread. |
Describe the bug
In the v2 repo this bug: aws/aws-sdk-js#3020 hinted at that in v3 there was going to be improvement around stack traces. So I decided to run some test wiht the v3 SDK to see if there is any improvements. Currently it does not show where the error was thrown within my application. This make it was hard to track down where the error is occurring.
SDK version number
@aws-sdk/client-s3: 1.0.0-gamma.2
Is the issue in the browser/Node.js?
Node.js
Details of the browser/Node.js version
v12.16.3
To Reproduce (observed behavior)
I created a simple application that should show the current behaviour.
https://github.com/Bene-Graham/AWS-SDK-StackTraceIssue
Expected behavior
I would expect that the stack trace should contain where in my application code the error was thrown. Currently it only show this:
The text was updated successfully, but these errors were encountered: