nodejs-storage icon indicating copy to clipboard operation
nodejs-storage copied to clipboard

Fix error serialization in resumable-upload.ts

Open eagleeye opened this issue 1 year ago • 1 comments

Existing error handling has wrong error serialization with .toString(), that leads to [object Object] error messages. Example: Error: Retry limit exceeded - [object Object] at Upload.attemptDelayedRetry (/usr/src/app/node_modules/@google-cloud/storage/build/cjs/src/resumable-upload.js:818:26)

Better solution would be JSON.stringify the error

Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:

  • [ ] Make sure to open an issue as a bug/issue before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
  • [ ] Ensure the tests and linter pass
  • [ ] Code coverage does not decrease (if any source code was changed)
  • [ ] Appropriate docs were updated (if necessary)

the issue was discussed with Google Support via DoIT support team as a intermediate

eagleeye avatar Jul 05 '24 06:07 eagleeye