nodejs-storage
nodejs-storage copied to clipboard
Fix error serialization in resumable-upload.ts
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