Skip to content

upgrade vulnerable dependencies and migrate to simple-git v4 - #739

Merged
TalUsvyatsky merged 6 commits into
DataDog:mainfrom
tusharf5:bump-deps
Oct 29, 2026
Merged

TalUsvyatsky merged 6 commits into
DataDog:mainfrom
tusharf5:bump-deps

Conversation

@tusharf5

@tusharf5 tusharf5 commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Dependency audits identified vulnerabilities in simple-git, @simple-git/argv-parser, basic-ftp, and other transitive dependencies across the root and e2e projects.

Upgrade affected dependencies, refresh both Yarn lockfiles, and replace the removed gitP() API with simpleGit(). Verify builds, tests, lint, formatting, and audits on Node 22 and 24.

Motivation

Lots of dependency vulnerabilities at work came from this plugin.

Testing Guidelines

Ran the test suite in both node 22 and node 24. Added new tests. If a beta release is possible, I am willing to test this at work in a real project.

Additional Notes

Types of changes

  • Bug fix
  • New feature
  • Breaking change
  • Misc (docs, refactoring, dependency upgrade, etc.)

Check all that apply

  • This PR's description is comprehensive
  • This PR contains breaking changes that are documented in the description
  • This PR introduces new APIs or parameters that are documented and unlikely to change in the foreseeable future
  • This PR impacts documentation, and it has been updated (or a ticket has been logged)
  • This PR's changes are covered by the automated tests
  • This PR collects user input/sensitive content into Datadog

@tusharf5

tusharf5 commented Oct 8, 2026

Copy link
Copy Markdown
Contributor Author

@nina9753 thanks for the approval. I just re-pushed the commit after signing it.

@tusharf5

Copy link
Copy Markdown
Contributor Author

updated the PR to resolve conflicts

TalUsvyatsky and others added 2 commits October 28, 2026 11:50
Bump @datadog/datadog-ci-base to ^5.26.1, which depends on simple-git
^4.0.2. Remove the simple-git resolution because it is no longer
necessary.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
simple-git 4 removes inherited GIT_* environment variables. The plugin's
newSimpleGit did not allow GIT_DIR and GIT_WORK_TREE, so source code
integration was skipped for repositories that use them. Use isGitRepo
from datadog-ci-base, which allows these variables and returns false
outside a git repository. Remove src/git.ts and the direct simple-git
dependency.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@nina9753 nina9753 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.

The Git helper cleanup looks good, and the new tests cover the main cases. One nonblocking follow-up: the basic-ftp resolution fixes installs in this repo, but consumers still resolve 5.3.1 through get-uri. Can we track the upstream dependency fix separately?

@TalUsvyatsky

Copy link
Copy Markdown
Contributor

The Git helper cleanup looks good, and the new tests cover the main cases. One nonblocking follow-up: the basic-ftp resolution fixes installs in this repo, but consumers still resolve 5.3.1 through get-uri. Can we track the upstream dependency fix separately?

@nina9753 Yes, we'll pull that in when it becomes available

@TalUsvyatsky
TalUsvyatsky merged commit 081ae6f into DataDog:main Oct 29, 2026
18 of 24 checks passed
@TalUsvyatsky TalUsvyatsky mentioned this pull request Oct 29, 2026
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.

3 participants