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

[cli] Reject template download if statusCode is not 2xx #1638

Merged
merged 1 commit into from
Nov 29, 2019

Conversation

rexxars
Copy link
Member

@rexxars rexxars commented Nov 28, 2019

When bootstrapping a plugin from a template URL, we were only checking for network errors, not HTTP errors. This makes it hard to debug problems such as a 404 response from the server, since it would end up with the hopeless error message of:

Error: Could not find package.json in template

This adds rejection logic based on the HTTP status code.

Copy link
Contributor

@thomax thomax left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

Copy link
Member

@skogsmaskin skogsmaskin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants