-
-
Notifications
You must be signed in to change notification settings - Fork 8.8k
[ci] Avoid fetching GTest with CMake. #11828
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
Conversation
|
Do you have a reason to believe that fetching gtest from Apt would lead to less flakiness than fetching it from GitHub? |
|
No reason. But in general, having it handled by a dependency manager makes things easier. For instance, we can cache them in a docker image if needed. Also, we don't have to build from source everytime. I would like to replace the dmlc gtest whenever the chance arises. |
|
If so, let's use Conda to install gtest. This way, we can also use it for MacOS and Windows as well. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR modifies the gtest-cpu-nonomp CI workflow to use a conda-provided GTest package instead of fetching GTest through CMake via the dmlc-core submodule. This change addresses a failure in the CI pipeline where CMake's automatic GTest fetch was failing.
- Removed
-DUSE_DMLC_GTEST=ONflag from the CMake build configuration - Switched from apt-get installation to conda environment setup with miniforge
- Added proper bash shell configuration for conda environment activation
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| ops/pipeline/build-test-cpu-nonomp.sh | Removed the -DUSE_DMLC_GTEST=ON CMake flag to use system-provided GTest instead of dmlc-core's bundled version |
| .github/workflows/misc.yml | Replaced apt-get installation with miniforge-setup action, configured proper bash shell for conda, and added cpp_test conda environment setup |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Prevent failure: https://github.com/dmlc/xgboost/actions/runs/19546987883/job/55969434054