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

Add better logging around failed response #155

Closed
DanielJoyce opened this issue Jan 12, 2022 · 1 comment · Fixed by #358
Closed

Add better logging around failed response #155

DanielJoyce opened this issue Jan 12, 2022 · 1 comment · Fixed by #358
Assignees

Comments

@DanielJoyce
Copy link
Contributor

When the cli gets back a non-200 result, it should log the issue and print out a helpful result

@kylewillmon
Copy link
Contributor

Here's a concrete example:

❯ phylum package -t npm doh 'git://git@github.com/fake/really-really-fake.git' 
❗ Response error:
expected value at line 1 column 1

@cd-work cd-work self-assigned this May 6, 2022
cd-work added a commit that referenced this issue May 6, 2022
This enhances the verbosity of errors when an HTTP request failed, by
providing the full response with a response code other than 200, rather
than trying to parse the response as valid JSON.

This should shed more insights on why the request failed, especially
when the user has connectivity issues.

Closes #155.
cd-work added a commit that referenced this issue May 6, 2022
This enhances the verbosity of errors when an HTTP request failed, by
providing the full response with a response code other than 200, rather
than trying to parse the response as valid JSON.

This should shed more insights on why the request failed, especially
when the user has connectivity issues.

Closes #155.
cd-work added a commit that referenced this issue May 9, 2022
This enhances the verbosity of errors when an HTTP request failed, by
providing the full response with a response code other than 200, rather
than trying to parse the response as valid JSON.

This should shed more insights on why the request failed, especially
when the user has connectivity issues.

Closes #155.
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 a pull request may close this issue.

3 participants