Skip to content

chore: address dependabot and code scanning alerts in build tools - #2165

Open
NathanWalker wants to merge 2 commits into
mainfrom
chore/security-alerts
Open

NathanWalker wants to merge 2 commits into
mainfrom
chore/security-alerts

Conversation

@NathanWalker

@NathanWalker NathanWalker commented Dec 1, 2026 •

Copy link
Copy Markdown
Contributor

What is the current behavior?

Dependabot reports 24 open alerts, and code scanning reports alerts in test files, a legacy build helper, and release/PR workflows. Every Dependabot alert is in test-app/build-tools:

  • The jsparser test package depends on babel 6 (babel-traverse, babel-types, babylon), lazy, lodash and jasmine-node. None of them are used: the specs only use child_process, path and fs, and drive the static binding generator through gradle. They bring in vulnerable underscore, lodash, xmldom, minimatch and brace-expansion.
  • android-metadata-generator/package.json lists grunt 0.4 devDependencies. There's no Gruntfile and nothing runs them.
  • jsparser builds with webpack 5.101.3.

What is the new behavior?

  • jsparser tests: the unused dependencies are removed (55 packages down to 17), and xmldom (0.8.15), minimatch (3.1.5) and brace-expansion (1.1.22) are refreshed. npm audit reports 0 vulnerabilities.
  • jsparser: webpack 5.113.0.
  • android-metadata-generator: the grunt devDependencies are removed.
  • Workflows:
    • actions/download-artifact@v8 is pinned to v8.0.2 by SHA, like the other actions.
    • test-app/tools is installed with npm ci from its lockfile.

Validation

  • jsparser AST tests (runAstTests): 11 specs, 0 failures before and after the change, run against a jsparser bundle rebuilt with webpack 5.113.0 and the trimmed test dependencies. They need the static binding generator jar built first: ./gradlew -p test-app/build-tools/static-binding-generator jar -PappRoot=/tmp -PgeneratedJavaClassesRoot=/tmp.
  • npm ci --prefix ./test-app/tools: succeeds, because the lockfile is in sync.

- jsparser tests: drop unused babel 6, babylon, lazy, lodash and
  jasmine-node dependencies (the specs only drive the static binding
  generator through gradle) and refresh xmldom, minimatch and
  brace-expansion in the lockfile
- jsparser: webpack 5.113.0
- android-metadata-generator: drop the unused grunt devDependencies
- jsparser tests: use A-Za-z instead of the overly large A-z range
- workflows: pin actions/download-artifact to v8.0.2 and install
  test-app/tools with npm ci from its lockfile
@coderabbitai

coderabbitai Bot commented Dec 1, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

Workflow install commands and artifact references changed. Build-tool package dependencies were removed or updated, and a parser metadata pattern now excludes punctuation previously matched by A-z.

Changes: Build and test tooling

Layer / File(s) Summary
Workflow installs and artifact downloads
.github/workflows/npm_release.yml, .github/workflows/pull_request.yml
Build and test jobs now use npm ci for ./test-app/tools. Artifact-download steps use the pinned actions/download-artifact v8.0.2 commit.
Build-tool dependencies and metadata pattern
test-app/build-tools/android-metadata-generator/package.json, test-app/build-tools/jsparser/package.json, test-app/build-tools/jsparser/tests/package.json, test-app/build-tools/jsparser/tests/specs/ast-parser-tests.spec.js
The android metadata generator and jsparser test packages remove dependencies. The jsparser package updates webpack to 5.113.0. The metadata pattern replaces A-z with A-Za-z ranges.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Other · Severity of issue fixed: Low

Suggested reviewers: edusperoni, vtrifonov

Merge Risk: Minimal · up to b6f91 · assessed changes only

Path filters excluded changed files. This rating applies only to the assessed changes.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names a chore that matches the changeset: it addresses Dependabot and code-scanning alerts in test-app/build-tools. The changes include trimming jsparser test dependencies, upgrading webpack…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Full details: Title check

Explanation

The title names a chore that matches the changeset: it addresses Dependabot and code-scanning alerts in test-app/build-tools. The changes include trimming jsparser test dependencies, upgrading webpack to 5.113.0, removing unused Grunt devDependencies, narrowing the A-z regex range to A-Za-z for the CodeQL alert, and pinning workflow actions and using npm ci. The title is specific and concise, and it reflects the primary change.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between fafd22a and b6f9158.

Files ignored due to path filters: 1

  • test-app/build-tools/jsparser/tests/package-lock.json is excluded by !**/package-lock.json
Files selected for processing: 6

  • .github/workflows/npm_release.yml
  • .github/workflows/pull_request.yml
  • test-app/build-tools/android-metadata-generator/package.json
  • test-app/build-tools/jsparser/package.json
  • test-app/build-tools/jsparser/tests/package.json
  • test-app/build-tools/jsparser/tests/specs/ast-parser-tests.spec.js
Files with no reviewable changes: 1

  • test-app/build-tools/jsparser/tests/package.json

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.

The test-only regex alerts are dismissed as used in tests; editing the line re-opens them under new fingerprints.

This branch has not been deployed

No deployments
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