Repository navigation
feat: check the whole dependency tree, add devcompass why, drop npm-check-updates - #13
Open
AjayBThorat-20 wants to merge 1 commit into
Open
AjayBThorat-20 wants to merge 1 commit into
AjayBThorat-20 wants to merge 1 commit into
Conversation
…-check-updates - A dependency graph built from package-lock.json alone (npm; pnpm/yarn/bun, no lockfile or lockfileVersion 1 report incomplete). Edges are resolved from the lockfile's install paths, so the graph is complete before `npm install` and links optional platform packages to their own nested dependencies. - The OSV check covers every installed name@version in that graph, not just direct dependencies (falls back to direct ones without a usable graph). On express@4.17.1 + lodash this finds 7 vulnerable packages instead of 4. OSV queries are chunked, 200 packages per request, 4 in flight. - `devcompass why <package>` prints every path from the project to each installed version of a package. - The outdated check uses the registry client instead of npx npm-check-updates (-6.3 MB). The cache now keeps the published version list, so `wanted` is the highest version the declared range allows. - Lockfile-only fixes for new follow-redirects and zod advisories.
4 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
Most vulnerabilities in a real project are in transitive dependencies, and the OSV check only looked at direct ones.
package-lock.jsonalone (npm; pnpm/yarn/bun, a missing lockfile or lockfileVersion 1 reportincompleteinstead of an empty graph). Edges come from the lockfile's install paths, so it's complete beforenpm installhas run.name@version. Onexpress@4.17.1+lodashit finds 7 vulnerable packages instead of 4. Queries are chunked (200 per request, 4 in flight).devcompass why <package>prints every path from the project to each installed version of a package.npm-check-updatesis gone (−6.3 MB). The outdated check uses the registry client DevCompass already ships;wantedis now the highest version the declared range allows, not alwayslatest.follow-redirectsandzodadvisories.Stacked on #12.
Merging the stack: use Create a merge commit, not squash (squashing makes every later PR show these commits again). After merging the PR below this one, click Delete branch on it; GitHub then retargets this PR to
mainand CI runs.How I tested it
npm run test:coverageon Node 24.21.0, cleannpm ci, network disabled: 152/152 pass, 38.66% linesnpm audit --audit-level=highcurrently fails on GHSA-mrwp-f3q8-3g9p (follow-redirects, published after this branch was made); the lockfile fix is in feat: rank vulnerabilities by exploit risk (CISA KEV + FIRST EPSS) #14analyzeon express@4.17.1 + lodash: 7 vulnerable packages (was 4)qs@6.9.0andexpress's nestedqs@6.7.0are separate nodes with the right edges, andwhylists every path to each🤖 Generated with Claude Code