Skip to content
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

[CI] fix git errors related to directory ownership #8628

Merged
merged 1 commit into from Jan 2, 2023

Conversation

jameslamb
Copy link
Contributor

The Test R package on Debian CI job is currently failing on master (build link) and on #8627 (build link) with the following error at the step where the repo is git clone'd.

ValueError: ('Failed to check git repository status.', CompletedProcess(args=['git', 'clean', '-xdf', '--dry-run'], returncode=128, stdout=b'', stderr=b"fatal: detected dubious ownership in repository at '/__w/xgboost/xgboost'\nTo add an exception for this directory, call:\n\n\tgit config --global --add safe.directory /__w/xgboost/xgboost\n"))

I suspect this means that that job started getting a newer version of git recently, which contains a patch for the CVE described at https://github.blog/2022-04-12-git-security-vulnerability-announced/.

This PR proposes a patch that I think will address it. We've been using something similar over in LightGBM for the last 8 months (microsoft/LightGBM#5152) without issue.

@hcho3 hcho3 merged commit dd72af2 into dmlc:master Jan 2, 2023
@hcho3
Copy link
Collaborator

hcho3 commented Jan 2, 2023

@jameslamb Thanks a ton!

@jameslamb jameslamb deleted the ci/trust-git-clone branch January 2, 2023 00:07
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.

None yet

2 participants