GH-51494: [CI][C++] Detect Visual Studio installed path instead of hardcoding it - #51610
Merged
Merged
Conversation
… of hardcoding it
|
|
raulcd
commented
Sep 28, 2026
raulcd
marked this pull request as ready for review
September 28, 2026 10:52
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
The ARM job still uses a runner image without Visual Studio, so discovery and setup will fail.
Review effort: Lite
Findings: 1
Open (1)
What changed in this PR
Updates Windows C++ CI to dynamically locate Visual Studio with vswhere instead of using a hardcoded path.
Changes:
- Detects the Visual Studio installation path.
- Uses it for build and test environment setup.
| File | Description |
|---|---|
.github/workflows/cpp_windows.yml |
Adds dynamic Visual Studio discovery and replaces hardcoded paths. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
kou
reviewed
Sep 28, 2026
Co-authored-by: Sutou Kouhei <kou@cozmixng.org>
Member
Author
|
@github-actions crossbow submit matlab |
|
Revision: 5480dde Submitted crossbow builds: ursacomputing/crossbow @ actions-ca8792eab0
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Rationale for this change
The Windows ARM job was failing on CMake configure. The real problem is that the Windows-11-arm64 GitHub runner updated VS Code from 2022 to 2026 here: actions/runner-images#14592
The workflow was hardcoding
vcvarsall.batpath and wasn't really setting those up.What changes are included in this PR?
Use vswhere to find VSCode installation path instead of manually setting it up.
I investigating using: https://github.com/ilammy/msvc-dev-cmd which is allowed by infra and used on nanoarrow and adbc but it feels unmaintained at the moment (No new releases in 3 years).
This has been changed everywhere where we were manually setting this path.
Are these changes tested?
Yes via CI
Are there any user-facing changes?
No
Was AI used for this PR?
In accordance to the AI generation guidelines, please disclose below whether and how AI was used in this PR.
PR code and description written by:
AI used to analyze and first implementation.
Re-implemented on a second bash step from me as it's much cleaner and clearer.
Reviewed before submission by: