Skip to content

Support VS2026.#12245

Merged
trivialfis merged 8 commits into
dmlc:masterfrom
trivialfis:test-vs2026
Jun 14, 2026
Merged

Support VS2026.#12245
trivialfis merged 8 commits into
dmlc:masterfrom
trivialfis:test-vs2026

Conversation

@trivialfis

@trivialfis trivialfis commented Jun 14, 2026

Copy link
Copy Markdown
Member

In addition to the VS2026 CMake generator, this patch drops support for older dask versions, reworks create_jni.py to handle pylint errors, and uses newer Python features as a drive-by cleanup.

close #11805

Copilot AI 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.

Pull request overview

This PR updates build tooling to recognize Visual Studio 2026 CMake generators, simplifies parts of the Dask integration by assuming newer Dask worker APIs, and refactors the JVM JNI build script (create_jni.py) to use more modern Python patterns and avoid shell-string subprocess calls.

Changes:

  • Add Visual Studio 2026 as a supported CMake generator on Windows for native library builds.
  • Update Dask thread detection to use worker.state.nthreads (dropping older worker APIs).
  • Refactor jvm-packages/create_jni.py to use pathlib, structured subprocess invocation, and clearer build/copy helpers.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
python-package/xgboost/dask/utils.py Assumes newer Dask worker API (worker.state.nthreads) for thread detection.
python-package/packager/nativelib.py Adds -GVisual Studio 18 2026 to the Windows generator fallback list.
jvm-packages/create_jni.py Refactors JNI build script and adds VS2026 generator attempts; restructures build/copy logic.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread jvm-packages/create_jni.py Outdated
@trivialfis
trivialfis requested a review from Copilot June 14, 2026 09:09

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@trivialfis

Copy link
Copy Markdown
Member Author

Merging to unblock the CI.

@trivialfis
trivialfis merged commit f03c6ce into dmlc:master Jun 14, 2026
113 of 114 checks passed
@trivialfis
trivialfis deleted the test-vs2026 branch June 14, 2026 11:13
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.

Support visual studio 2026

2 participants