Skip to content

Conversation

@paddyroddy
Copy link
Contributor

@paddyroddy paddyroddy commented Jul 20, 2025

Rationale for this change

When building locally, I get many errors along the lines of

Please ensure the files specified are contained by the root
of the Python package (normally marked by `pyproject.toml`).

By 2026-Mar-20, you need to update your project and remove deprecated calls
or your builds will no longer be supported.

See https://packaging.python.org/en/latest/specifications/glob-patterns/ for details.
terminal demo

What changes are included in this PR?

  • Make the licence SPDX compliant
  • Remove the licence classifier
  • Move the licence files from setup.cfg to pyproject.toml
  • Fix the disallowed glob patterns via symlinks
  • Bumped the minimum version of setuptools due to macOS CI failures (don't know why this happened, caching maybe?)

I appreciate the symlink change might prove controversial. See discussions in #45867, fixes #45867.

Are these changes tested?

When I rebuild locally, I get no errors any more.

Are there any user-facing changes?

Yes. The minimum required version of setuptools is now 77. However, this is available on >=3.9 so won't affect anyone really.

@github-actions
Copy link

⚠️ GitHub issue #45867 has been automatically assigned in GitHub to PR creator.

@github-actions
Copy link

⚠️ GitHub issue #45867 has been automatically assigned in GitHub to PR creator.

# versions released after 2022
"setuptools_scm[toml]>=8",
"setuptools>=64",
"setuptools>=77",
Copy link
Member

Choose a reason for hiding this comment

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

This is required due to setuptools<77 not recognizing the new license strings proposed in this PR (see pypa/setuptools#4903 for explanation). I'm not sure if this is controversial so bringing it up here. @raulcd

@github-actions github-actions bot added awaiting changes Awaiting changes and removed awaiting review Awaiting review labels Jul 20, 2025
@rok
Copy link
Member

rok commented Jul 20, 2025

@github-actions crossbow submit

@github-actions
Copy link

no tasks were provided for the job
The Archery job run can be found at: https://github.com/apache/arrow/actions/runs/16398862798

@raulcd
Copy link
Member

raulcd commented Jul 20, 2025

@github-actions crossbow submit -g python -g wheels

@github-actions
Copy link

Invalid group(s) {'wheels'}. Must be one of {'example-cpp', 'python', 'nightly-release', 'cpp', 'verify-rc-source-macos', 'wheel', 'test', 'verify-rc-source', 'cuda', 'vcpkg', 'linux-amd64', 'conan', 'r', 'nightly', 'ruby', 'linux', 'c-glib', 'linux-arm64', 'verify-rc-source-linux', 'example', 'packaging', 'integration', 'example-python', 'fuzz', 'nightly-tests', 'verify-rc', 'homebrew', 'nightly-packaging'}
The Archery job run can be found at: https://github.com/apache/arrow/actions/runs/16398880949

@raulcd
Copy link
Member

raulcd commented Jul 20, 2025

@github-actions crossbow submit -g python

@github-actions
Copy link

Revision: 6b1a08b

Submitted crossbow builds: ursacomputing/crossbow @ actions-2fdf3226a1

Task Status
example-python-minimal-build-fedora-conda GitHub Actions
example-python-minimal-build-ubuntu-venv GitHub Actions
test-conda-python-3.10 GitHub Actions
test-conda-python-3.10-hdfs-2.9.2 GitHub Actions
test-conda-python-3.10-hdfs-3.2.1 GitHub Actions
test-conda-python-3.10-pandas-latest-numpy-latest GitHub Actions
test-conda-python-3.11 GitHub Actions
test-conda-python-3.11-dask-latest GitHub Actions
test-conda-python-3.11-dask-upstream_devel GitHub Actions
test-conda-python-3.11-hypothesis GitHub Actions
test-conda-python-3.11-pandas-latest-numpy-1.26 GitHub Actions
test-conda-python-3.11-pandas-latest-numpy-latest GitHub Actions
test-conda-python-3.11-pandas-nightly-numpy-nightly GitHub Actions
test-conda-python-3.11-pandas-upstream_devel-numpy-nightly GitHub Actions
test-conda-python-3.11-spark-master GitHub Actions
test-conda-python-3.12 GitHub Actions
test-conda-python-3.12-cpython-debug GitHub Actions
test-conda-python-3.13 GitHub Actions
test-conda-python-3.9 GitHub Actions
test-conda-python-3.9-pandas-1.1.3-numpy-1.19.5 GitHub Actions
test-conda-python-emscripten GitHub Actions
test-cuda-python-ubuntu-22.04-cuda-11.7.1 GitHub Actions
test-debian-12-python-3-amd64 GitHub Actions
test-debian-12-python-3-i386 GitHub Actions
test-fedora-42-python-3 GitHub Actions
test-ubuntu-22.04-python-3 GitHub Actions
test-ubuntu-22.04-python-313-freethreading GitHub Actions
test-ubuntu-24.04-python-3 GitHub Actions

Copy link
Member

Choose a reason for hiding this comment

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

Does symbolic link work on Windows...?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good point. I guess there's no other way to fix it then other than copying or creating new licence and notice files.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Have copied over the files for the tests @rok

Copy link
Contributor

Choose a reason for hiding this comment

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

Per https://gitforwindows.org/symbolic-links.html:

Short version: there is no exact equivalent for POSIX symlinks on Windows, and the closest thing is unavailable for non-admins by default unless Developer Mode is enabled and a relatively recent Windows 10 version is used. Therefore, symlink emulation support is only turned on by default when that scenario is detected. Support can be enabled by the user, via the core.symlinks=true config setting.

Windows 10 reached EOL last month, and supposedly Developer Mode is required for Visual Studio use.

I'm not sure of all the Windows workflows that may / may not require developer mode, but maybe its worth just requiring it for any Windows devs of PyArrow so that symlinks can be used?

@kou
Copy link
Member

kou commented Jul 20, 2025

@github-actions crossbow submit -g wheel

@kou kou changed the title GH-45867: [PYTHON] Fix SetuptoolsDeprecationWarning GH-45867: [Python] Fix SetuptoolsDeprecationWarning Jul 20, 2025
@github-actions
Copy link

⚠️ GitHub issue #45867 has been automatically assigned in GitHub to PR creator.

@github-actions
Copy link

Revision: 6b1a08b

Submitted crossbow builds: ursacomputing/crossbow @ actions-fe79dfe84b

Task Status
python-sdist GitHub Actions
wheel-macos-monterey-cp310-cp310-amd64 GitHub Actions
wheel-macos-monterey-cp310-cp310-arm64 GitHub Actions
wheel-macos-monterey-cp311-cp311-amd64 GitHub Actions
wheel-macos-monterey-cp311-cp311-arm64 GitHub Actions
wheel-macos-monterey-cp312-cp312-amd64 GitHub Actions
wheel-macos-monterey-cp312-cp312-arm64 GitHub Actions
wheel-macos-monterey-cp313-cp313-amd64 GitHub Actions
wheel-macos-monterey-cp313-cp313-arm64 GitHub Actions
wheel-macos-monterey-cp313-cp313t-amd64 GitHub Actions
wheel-macos-monterey-cp313-cp313t-arm64 GitHub Actions
wheel-macos-monterey-cp39-cp39-amd64 GitHub Actions
wheel-macos-monterey-cp39-cp39-arm64 GitHub Actions
wheel-manylinux-2-28-cp310-cp310-amd64 GitHub Actions
wheel-manylinux-2-28-cp310-cp310-arm64 GitHub Actions
wheel-manylinux-2-28-cp311-cp311-amd64 GitHub Actions
wheel-manylinux-2-28-cp311-cp311-arm64 GitHub Actions
wheel-manylinux-2-28-cp312-cp312-amd64 GitHub Actions
wheel-manylinux-2-28-cp312-cp312-arm64 GitHub Actions
wheel-manylinux-2-28-cp313-cp313-amd64 GitHub Actions
wheel-manylinux-2-28-cp313-cp313-arm64 GitHub Actions
wheel-manylinux-2-28-cp313-cp313t-amd64 GitHub Actions
wheel-manylinux-2-28-cp313-cp313t-arm64 GitHub Actions
wheel-manylinux-2-28-cp39-cp39-amd64 GitHub Actions
wheel-manylinux-2-28-cp39-cp39-arm64 GitHub Actions
wheel-musllinux-1-2-cp310-cp310-amd64 GitHub Actions
wheel-musllinux-1-2-cp310-cp310-arm64 GitHub Actions
wheel-musllinux-1-2-cp311-cp311-amd64 GitHub Actions
wheel-musllinux-1-2-cp311-cp311-arm64 GitHub Actions
wheel-musllinux-1-2-cp312-cp312-amd64 GitHub Actions
wheel-musllinux-1-2-cp312-cp312-arm64 GitHub Actions
wheel-musllinux-1-2-cp313-cp313-amd64 GitHub Actions
wheel-musllinux-1-2-cp313-cp313-arm64 GitHub Actions
wheel-musllinux-1-2-cp313-cp313t-amd64 GitHub Actions
wheel-musllinux-1-2-cp313-cp313t-arm64 GitHub Actions
wheel-musllinux-1-2-cp39-cp39-amd64 GitHub Actions
wheel-musllinux-1-2-cp39-cp39-arm64 GitHub Actions
wheel-windows-cp310-cp310-amd64 GitHub Actions
wheel-windows-cp311-cp311-amd64 GitHub Actions
wheel-windows-cp312-cp312-amd64 GitHub Actions
wheel-windows-cp313-cp313-amd64 GitHub Actions
wheel-windows-cp313-cp313t-amd64 GitHub Actions
wheel-windows-cp39-cp39-amd64 GitHub Actions

@paddyroddy
Copy link
Contributor Author

Sorry, I'm struggling to find time to look into the SDist if anyone else could have a look

@rok
Copy link
Member

rok commented Dec 16, 2025

The macOS segfaults are expected and unrelated.

Copy link
Member

@rok rok left a comment

Choose a reason for hiding this comment

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

This looks pretty good to me! @raulcd

@github-actions github-actions bot added awaiting changes Awaiting changes and removed awaiting change review Awaiting change review labels Dec 16, 2025
@rok rok requested a review from pitrou December 17, 2025 22:54
@github-actions github-actions bot added awaiting change review Awaiting change review and removed awaiting changes Awaiting changes labels Dec 18, 2025
@pitrou
Copy link
Member

pitrou commented Dec 18, 2025

@github-actions crossbow submit -g python

@pitrou
Copy link
Member

pitrou commented Dec 18, 2025

@github-actions crossbow submit wheelcp313*

@github-actions
Copy link

Revision: e47ca7c

Submitted crossbow builds: ursacomputing/crossbow @ actions-1176ee40f3

Task Status
wheel-macos-monterey-cp313-cp313-amd64 GitHub Actions
wheel-macos-monterey-cp313-cp313-arm64 GitHub Actions
wheel-macos-monterey-cp313-cp313t-amd64 GitHub Actions
wheel-macos-monterey-cp313-cp313t-arm64 GitHub Actions
wheel-manylinux-2-28-cp313-cp313-amd64 GitHub Actions
wheel-manylinux-2-28-cp313-cp313-arm64 GitHub Actions
wheel-manylinux-2-28-cp313-cp313t-amd64 GitHub Actions
wheel-manylinux-2-28-cp313-cp313t-arm64 GitHub Actions
wheel-musllinux-1-2-cp313-cp313-amd64 GitHub Actions
wheel-musllinux-1-2-cp313-cp313-arm64 GitHub Actions
wheel-musllinux-1-2-cp313-cp313t-amd64 GitHub Actions
wheel-musllinux-1-2-cp313-cp313t-arm64 GitHub Actions
wheel-windows-cp313-cp313-amd64 GitHub Actions
wheel-windows-cp313-cp313t-amd64 GitHub Actions

@github-actions
Copy link

Revision: e47ca7c

Submitted crossbow builds: ursacomputing/crossbow @ actions-8124fa0f6c

Task Status
example-python-minimal-build-fedora-conda GitHub Actions
example-python-minimal-build-ubuntu-venv GitHub Actions
test-conda-python-3.10 GitHub Actions
test-conda-python-3.10-hdfs-2.9.2 GitHub Actions
test-conda-python-3.10-hdfs-3.2.1 GitHub Actions
test-conda-python-3.10-pandas-1.3.4-numpy-1.21.2 GitHub Actions
test-conda-python-3.11 GitHub Actions
test-conda-python-3.11-dask-latest GitHub Actions
test-conda-python-3.11-dask-upstream_devel GitHub Actions
test-conda-python-3.11-hypothesis GitHub Actions
test-conda-python-3.11-pandas-latest-numpy-latest GitHub Actions
test-conda-python-3.11-spark-master GitHub Actions
test-conda-python-3.12 GitHub Actions
test-conda-python-3.12-cpython-debug GitHub Actions
test-conda-python-3.12-pandas-latest-numpy-1.26 GitHub Actions
test-conda-python-3.12-pandas-latest-numpy-latest GitHub Actions
test-conda-python-3.13 GitHub Actions
test-conda-python-3.13-pandas-nightly-numpy-nightly GitHub Actions
test-conda-python-3.13-pandas-upstream_devel-numpy-nightly GitHub Actions
test-conda-python-3.14 GitHub Actions
test-conda-python-emscripten GitHub Actions
test-cuda-python-ubuntu-22.04-cuda-11.7.1 GitHub Actions
test-cuda-python-ubuntu-24.04-cuda-13.0.2 GitHub Actions
test-debian-12-python-3-amd64 GitHub Actions
test-debian-12-python-3-i386 GitHub Actions
test-fedora-42-python-3 GitHub Actions
test-ubuntu-22.04-python-3 GitHub Actions
test-ubuntu-22.04-python-313-freethreading GitHub Actions
test-ubuntu-24.04-python-3 GitHub Actions

@pitrou
Copy link
Member

pitrou commented Dec 18, 2025

CI failures are unrelated, thanks a lot @paddyroddy !

@pitrou
Copy link
Member

pitrou commented Dec 18, 2025

@github-actions crossbow submit python-sdist

@github-actions
Copy link

Revision: e47ca7c

Submitted crossbow builds: ursacomputing/crossbow @ actions-b1e74a8dee

Task Status
python-sdist GitHub Actions

@pitrou pitrou merged commit 866502e into apache:main Dec 18, 2025
31 checks passed
@pitrou pitrou removed the awaiting change review Awaiting change review label Dec 18, 2025
@conbench-apache-arrow
Copy link

After merging your PR, Conbench analyzed the 2 benchmarking runs that have been run so far on merge-commit 866502e.

There were no benchmark performance regressions. 🎉

The full Conbench report has more details. It also includes information about 1 possible false positive for unstable benchmarks that are known to sometimes produce them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[CI][Python] A new version (77.0.2) of setuptools seems to have broken some of our builds

7 participants