Skip to content

chore(deps): update npm dependencies#129

Closed
gorzell wants to merge 2 commits into
mainfrom
gorzell/fix-dependabot-43
Closed

chore(deps): update npm dependencies#129
gorzell wants to merge 2 commits into
mainfrom
gorzell/fix-dependabot-43

Conversation

@gorzell

@gorzell gorzell commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

Summary

Removes the vulnerable npm dependency chain in crates/string-offsets/js that pulled in js-yaml through Jest/Istanbul coverage tooling. Instead of using an npm override across a semver-incompatible major version, the JS sanity tests now use Node's built-in node:test runner and node:assert/strict.

Changed packages:

  • Removed direct dev dependencies: jest, @types/jest
  • Removed transitive vulnerable dependency chain: babel-plugin-istanbul -> @istanbuljs/load-nyc-config -> js-yaml
  • Removed the prior npm overrides entry

Security alerts resolved

Reviewer notes

There is no current stable native upgrade path in the Jest/Istanbul dependency chain: the latest @istanbuljs/load-nyc-config still declares js-yaml: ^3.13.1, and the latest stable Jest transform chain still pulls that package through babel-plugin-istanbul. Removing Jest for these two small sanity tests avoids both the semver-incompatible override and the argparse license change noted in review.

Validation

  • npm test in crates/string-offsets/js
  • make lint
  • make test
  • make build
  • make build-js

Generated by the update-deps skill.

Updated packages:
- js-yaml: 3.14.2 -> 4.2.0
- argparse: 1.0.10 -> 2.0.1

Resolved Dependabot alert 43 / GHSA-h67p-54hq-rp68 by using an npm override for the transitive development dependency pulled in by Jest coverage tooling.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@gorzell gorzell requested a review from a team as a code owner June 16, 2026 07:10
Copilot AI review requested due to automatic review settings June 16, 2026 07:10
GitHub Advanced Security started work on behalf of gorzell June 16, 2026 07:10 View session
GitHub Advanced Security finished work on behalf of gorzell June 16, 2026 07:11

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Not ready to approve

The override forces a semver-incompatible major js-yaml upgrade for at least one transitive consumer and introduces a license change (argparse), both of which should be addressed/confirmed before approval.

Pull request overview

Updates the JS dependency graph for crates/string-offsets/js by adding an npm overrides entry and regenerating the lockfile to move js-yaml to a patched version intended to resolve Dependabot alert 43.

Changes:

  • Added an npm overrides rule to force js-yaml to ^4.2.0.
  • Regenerated package-lock.json to reflect js-yaml@4.2.0 and its updated transitive deps (argparse@2.0.1), removing now-unused packages (esprima, sprintf-js).
File summaries
File Description
crates/string-offsets/js/package.json Adds an npm override to force js-yaml to a patched major version.
crates/string-offsets/js/package-lock.json Updates resolved dependency tree to js-yaml@4.2.0 and prunes no-longer-needed transitive packages.

Copilot's findings

Files not reviewed (1)

  • crates/string-offsets/js/package-lock.json: Generated file
  • Files reviewed: 1/2 changed files
  • Comments generated: 2

Note

Your feedback helps us improve the quality of this feature.
Please use 👍 or 👎 to tell us whether this assessment is correct.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 3166 to 3184
"node_modules/js-yaml": {
"version": "3.14.2",
"resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz",
"integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==",
"version": "4.2.0",
"resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.2.0.tgz",
"integrity": "sha512-ePWsvanv0DWuDRsW8dnt+R4jQ31SCRCQ7hhNcPXZPsoBZiemuZNYGf7adZdqX2D86j6rvKp3RpCxVTSb8WQlOw==",
"dev": true,
"funding": [
{
"type": "github",
"url": "https://github.com/sponsors/puzrin"
},
{
"type": "github",
"url": "https://github.com/sponsors/nodeca"
}
],
"license": "MIT",
"dependencies": {
"argparse": "^1.0.7",
"esprima": "^4.0.0"
"argparse": "^2.0.1"
},

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Addressed by removing the Jest/Istanbul dependency chain rather than overriding js-yaml. The JS sanity tests now use Node built-ins (node:test and node:assert/strict), so @istanbuljs/load-nyc-config and its js-yaml@^3.13.1 dependency are no longer present in the lockfile.

Comment on lines 1602 to 1608
"node_modules/argparse": {
"version": "1.0.10",
"resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz",
"integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==",
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz",
"integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==",
"dev": true,
"license": "MIT",
"dependencies": {
"sprintf-js": "~1.0.2"
}
"license": "Python-2.0"
},

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Addressed by removing the Jest/Istanbul dependency chain. argparse is no longer present in the regenerated lockfile, so the Python-2.0 license change is avoided.

Replace Jest with Node's built-in test runner for the string-offsets JS sanity tests. This removes the transitive Istanbul dependency chain that pulled in vulnerable js-yaml, avoiding a semver-incompatible override.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
GitHub Advanced Security started work on behalf of gorzell June 16, 2026 09:52 View session
@gorzell gorzell closed this Jun 16, 2026
GitHub Advanced Security finished work on behalf of gorzell June 16, 2026 09:53
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.

2 participants