Skip to content

Replace versioneer with setuptools-scm#12133

Merged
jacobtomlinson merged 6 commits intodask:mainfrom
jacobtomlinson:setuptools-scm
Nov 6, 2025
Merged

Replace versioneer with setuptools-scm#12133
jacobtomlinson merged 6 commits intodask:mainfrom
jacobtomlinson:setuptools-scm

Conversation

@jacobtomlinson
Copy link
Copy Markdown
Member

@jacobtomlinson jacobtomlinson commented Nov 4, 2025

Given that setuptools-scm is more widely used and better maintained than versioneer (last release was July 2023) we might want to switch.

  • Updated pyproject.toml to use setuptools-scm
  • Removed the dask/_version.py file as setuptools-scm generates this during sdist/wheel build (or pip install -e .)
  • Pulled in change from Remove unused setup.py #12132 which was needed for this
  • Removed dask/dataframe/dask_expr/_version.py as this looked unused

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Nov 4, 2025

Unit Test Results

See test report for an extended history of previous test failures. This is useful for diagnosing flaky tests.

      9 files  ±0        9 suites  ±0   3h 7m 40s ⏱️ - 7m 44s
 18 139 tests ±0   16 922 ✅  - 2   1 215 💤 ±0  2 ❌ +2 
162 479 runs  ±0  150 383 ✅  - 2  12 094 💤 ±0  2 ❌ +2 

For more details on these failures, see this check.

Results for commit 38fd9a1. ± Comparison against base commit 88fd00d.

♻️ This comment has been updated with latest results.

@jacobtomlinson jacobtomlinson marked this pull request as ready for review November 4, 2025 12:48
@DimitriPapadopoulos
Copy link
Copy Markdown
Contributor

Also adapt this comment:

# FIXME: This test isn't sensitive to projects that use git tags
# to determine versions (e.g. versioneer) when installed
# directly from GitHub as the latest `main` branch can sometimes
# be pointing to a released version of the project.

See #12039.

@jacobtomlinson
Copy link
Copy Markdown
Member Author

Sorry @DimitriPapadopoulos I totally missed #12039 when you originally opened it, probably because it's still a draft.

@jacobtomlinson jacobtomlinson merged commit 8e56d13 into dask:main Nov 6, 2025
23 of 25 checks passed
@jacobtomlinson jacobtomlinson deleted the setuptools-scm branch November 6, 2025 16:44

try:
# Backwards compatibility with versioneer
from dask._version import __commit_id__ as __git_revision__
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.

__commit_id__ was only added in setuptools-scm 9, and since this is in the same try, it means it's required to get a functional dask version. Should the setuptools-scm dependency get a minimum version, or should this try block be split so that it's optional?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In future please open a new issue instead of commenting on closed PRs. We probably need a minimum version.

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