Closed sargunv closed 1 year ago
I am pretty sure this is the case for all package managers. Since every package manager implementation attempts to JSON.parse
, we can probably use consistent behaviour.
Perhaps we just wrap all JSON.parse
for all package managers in a try/catch
and rethrow the error to include the response itself?
Closed with #306, released in v6.6.1
Currently, if
yarn npm audit
has some error (other than detected vulns),audit-ci
with fail with an error like this:Instead, audit-ci's thrown error message should probably include some info about the error Yarn reported.
I ran into this in #298 , and also when trying to bump the tested Yarn version in PR #300 (CI link here)