-
Notifications
You must be signed in to change notification settings - Fork 2
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
Support new npm audit JSON format #542
Comments
ediblecode
added a commit
to nice-digital/cks-gatsby
that referenced
this issue
Jul 27, 2022
Hey @ediblecode! Thanks for the report and for the link to the article, it helps a lot. It seems the logic was changed quite a bit, but I can try to come up with something. Of course, feel free to create a PR, I'd be happy to review it. |
kavithanice
pushed a commit
to nice-digital/cks-gatsby
that referenced
this issue
Aug 10, 2022
* CKS-642 Update packages * CKS-642 Rebrand * CKS-642 Refactor to use NDS alphabet/A-Z * CKS-642 Bump Node to 14 * CKS-642 Refactor A to Z using NDS component * CKS-642 Remove TeamCity audit reporter See cy6erskunk/npm-audit-reporter-teamcity#542 * CKS-642 Use link component for A-Z * CKS-642 Make 'on this page' Inter * CKS-642 Make accordion Inter * CKS-642 Bump NDS version * CKS-642 Remove audit TC reporter * CKS-642 Update snapshot * CKS-642 Increase test timeout * CKS-642 Fix test * CKS-642 Bump func test packages * CKS-642 Bump packages * CKS-642 Change audit command * CKS-642 Bump NDS version * CKS-642 Bump NDS and GN versions * CKS-642 Fix test * CKS-642 Bump NDS version * CKS-642 NDS version bump * CKS-642 Bump major NDS version Co-authored-by: Chris Barker <chris.barker@nice.org.uk>
This was referenced Jan 5, 2023
Done with #584, released in |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It looks like npm 7+ has changed the format of the JSON returned from
npm audit --json
. There's a great post here that explains a lot of the details.So this line where we get
auditResult.advisories
would need to traverse overauditResult.vulnerabilities
etc instead, based on the presence of the newauditReportVersion
field:npm-audit-reporter-teamcity/src/reporter.ts
Line 116 in 81cba9a
To replicated, I'm using volta locally. If I run:
I see npm 6 and the old JSON format that looks like:
Then if I run
I see npm 8 and the new JSON format that looks like:
The text was updated successfully, but these errors were encountered: