FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

[3.11] gh-135374: Adjust test for setuptools' replacement of distutils by encukou · Pull Request #138796 · python/cpython · GitHub

/ cpython Public

[3.11] gh-135374: Adjust test for setuptools' replacement of distutils - #138796

Merged
ambv merged 2 commits into
python:3.11from
encukou:setuptools-test-workaround
Sep 24, 2025
Merged

ambv merged 2 commits into
python:3.11from
encukou:setuptools-test-workaround

Conversation

encukou commented Sep 11, 2025 •
edited by bedevere-app Bot
Loading

Copy link
Copy Markdown
Member

ensurepip installs a bundled copy of distutils, which overrides the stdlib module. This affects several tests. This commit:

  • skips distutils in test___all__, as we're unlikely to break __all__ in a security-fix-only branch (and if we do it's not much of a a big deal)
  • skips importability tests of distutils submodules if the setuptools hack is detected

ensurepip installs a bundled copy of distutils, which overrides
the stdlib module. This affects several tests. This commit:

- skips distutils in test___all__, as we're unlikely to break
  `__all__` in a security-fix-only branch (and if we do it's not
  much of a a big deal)
- skips importability tests of distutils submodules if the
  setuptools hack is detected

encukou commented Sep 11, 2025

Copy link
Copy Markdown
Member Author

!buildbot Installed

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @encukou for commit 86a50bf 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F138796%2Fmerge

The command will test the builders whose names match following regular expression: Installed

The builders matched are:

  • x86 Debian Installed with X PR
  • AMD64 Fedora Stable Clang Installed PR
  • s390x Fedora Rawhide Clang Installed PR
  • AMD64 Fedora Rawhide Clang Installed PR
  • PPC64LE Fedora Rawhide Clang Installed PR
  • PPC64LE Fedora Stable Clang Installed PR
  • s390x Fedora Stable Clang Installed PR
  • aarch64 Fedora Rawhide Clang Installed PR
  • aarch64 Fedora Stable Clang Installed PR

encukou commented Sep 11, 2025

Copy link
Copy Markdown
Member Author

#138755 should fix the GHA failure.

zware left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

One cleanup suggestion, otherwise LGTM.

Comment thread Lib/test/test_sundry.py

encukou commented Sep 12, 2025

Copy link
Copy Markdown
Member Author

FWIW, the distutits modules that aren't present in setuptools 79 are:

emmatyping left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

One typo fix, but otherwise looks good!

Comment thread Lib/test/test___all__.py Outdated
Co-authored-by: Emma Smith <emma@emmatyping.dev>
ambv merged commit 987af36 into python:3.11 Sep 24, 2025
21 checks passed

Copy link
Copy Markdown

Thanks @encukou for the PR, and @ambv for merging it 🌮🎉.. I'm working now to backport this PR to: 3.9, 3.10.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 24, 2025
…stutils (pythonGH-138796)

ensurepip installs a bundled copy of distutils, which overrides
the stdlib module. This affects several tests. This commit:

- skips distutils in test___all__, as we're unlikely to break
  `__all__` in a security-fix-only branch (and if we do it's not
  much of a a big deal)
- skips importability tests of distutils submodules if the
  setuptools hack is detected
(cherry picked from commit 987af36)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Co-authored-by: Emma Smith <emma@emmatyping.dev>
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 24, 2025
…stutils (pythonGH-138796)

ensurepip installs a bundled copy of distutils, which overrides
the stdlib module. This affects several tests. This commit:

- skips distutils in test___all__, as we're unlikely to break
  `__all__` in a security-fix-only branch (and if we do it's not
  much of a a big deal)
- skips importability tests of distutils submodules if the
  setuptools hack is detected
(cherry picked from commit 987af36)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Co-authored-by: Emma Smith <emma@emmatyping.dev>

bedevere-app Bot commented Sep 24, 2025

Copy link
Copy Markdown

GH-139303 is a backport of this pull request to the 3.10 branch.

bedevere-app Bot removed the needs backport to 3.10 only security fixes label Sep 24, 2025

bedevere-app Bot commented Sep 24, 2025

Copy link
Copy Markdown

GH-139304 is a backport of this pull request to the 3.9 branch.

encukou deleted the setuptools-test-workaround branch September 24, 2025 13:44
ambv added a commit that referenced this pull request Sep 29, 2025
GH-138796) (GH-139303)

ensurepip installs a bundled copy of distutils, which overrides
the stdlib module. This affects several tests. This commit:

- skips distutils in test___all__, as we're unlikely to break
  `__all__` in a security-fix-only branch (and if we do it's not
  much of a a big deal)
- skips importability tests of distutils submodules if the
  setuptools hack is detected
(cherry picked from commit 987af36)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Co-authored-by: Emma Smith <emma@emmatyping.dev>
ambv added a commit that referenced this pull request Oct 7, 2025
…GH-138796) (GH-139304)

ensurepip installs a bundled copy of distutils, which overrides
the stdlib module. This affects several tests. This commit:

- skips distutils in test___all__, as we're unlikely to break
  `__all__` in a security-fix-only branch (and if we do it's not
  much of a a big deal)
- skips importability tests of distutils submodules if the
  setuptools hack is detected
(cherry picked from commit 987af36)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Co-authored-by: Emma Smith <emma@emmatyping.dev>
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

Labels

skip news tests Tests in the Lib/test dir

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants


Back | FazBrowse Home | New Git URL