Skip to content
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

fix: handle s3 errors without a status code #700

Merged
merged 1 commit into from
Feb 17, 2024

Conversation

barrywoolgar
Copy link
Contributor

Type: Bug
Scope: verdaccio-aws-s3-storage

The following has been addressed in the PR:

  • When an error occurs with the SDK outside of an HTTP request then the error's statusCode will be undefined, which will trigger a TypeError in common code outside the plugin, masking the true error (eg. missing AWS credentials)

This change sets a fallback 500 status code so that error handling will continue.

Resolves #695

If an error occurs with the SDK before an HTTP request is made then the error's statusCode will be `undefined`, which will trigger a TypeError in common code outside the plugin. 

This change sets a fallback 500 status code so that error handling can continue.
@barrywoolgar barrywoolgar changed the title Handle S3 errors without a statusCode fix: handle s3 errors without a status code Feb 15, 2024
@juanpicado juanpicado merged commit f5393f3 into verdaccio:main Feb 17, 2024
20 checks passed
@juanpicado juanpicado added the bug Something isn't working label Feb 17, 2024
@juanpicado
Copy link
Member

ref #704

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

aws-s3-storage-verdaccio: TypeError: argument #1 unsupported type undefined
2 participants