Skip to content

Add missing build-backend to pyproject.toml#252

Merged
saghul merged 1 commit into
aio-libs:masterfrom
mgorny:backend
May 16, 2026
Merged

Add missing build-backend to pyproject.toml#252
saghul merged 1 commit into
aio-libs:masterfrom
mgorny:backend

Conversation

@mgorny
Copy link
Copy Markdown
Contributor

@mgorny mgorny commented May 16, 2026

What do these changes do?

Add the missing build-backend entry to pyproject.toml, to fix building with tools that strictly implement PEP 517. PEP 517 requires the entry to be present, providing a fallback to the deprecated legacy setuptools backend if setup.py is present, which is not the case here.

Are there changes in behavior for the user?

Building from source distribution starts working for some users.

Related issue number

Checklist

  • I think the code is well written
  • Unit tests for the changes exist
  • Documentation reflects the changes

Add the missing `build-backend` entry to `pyproject.toml`, to fix
building with tools that strictly implement PEP 517.  PEP 517 requires
the entry to be present, providing a fallback to the deprecated legacy
setuptools backend _if_ `setup.py` is present, which is not the case
here.

Signed-off-by: Michał Górny <mgorny@gentoo.org>
@codecov
Copy link
Copy Markdown

codecov Bot commented May 16, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.42%. Comparing base (ac5c746) to head (969da46).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #252   +/-   ##
=======================================
  Coverage   98.42%   98.42%           
=======================================
  Files           5        5           
  Lines        1399     1399           
  Branches       73       73           
=======================================
  Hits         1377     1377           
  Misses         16       16           
  Partials        6        6           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown
Contributor

Copilot AI left a 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 updates the project’s packaging configuration to make PEP 517 builds work reliably by explicitly defining the setuptools build backend in pyproject.toml, avoiding reliance on legacy fallback behavior.

Changes:

  • Add build-backend = "setuptools.build_meta" under [build-system] in pyproject.toml.

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

Comment thread pyproject.toml
@@ -36,6 +36,7 @@ version = {attr = "aiodns.__version__"}
[build-system]
# pycares required because of the fact that it's in the __init__ module
requires = ["setuptools", "pycares"]
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This is complete and utter bullshit. wheel was never required, as setuptools always added it automatically via get_requires_for_build_wheel. It only was listed in documentation as a mistake, that was fixed long ago.

@saghul saghul enabled auto-merge (squash) May 16, 2026 07:40
@saghul saghul merged commit 6496021 into aio-libs:master May 16, 2026
28 checks passed
@bdraco bdraco mentioned this pull request May 20, 2026
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