-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove most of setuptools._distutils
#9795
Merged
Merged
Changes from 5 commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
b663057
Remove most _distutils
Avasam f95f804
Update refs
Avasam ba7bbb0
Fix Liskov substitution principle violation
Avasam 4be1d84
Update stubs/setuptools/METADATA.toml
Avasam 533acd4
Merge branch 'main' into cleanup-_distutils
Avasam abe4a12
Merge branch 'main' of https://github.com/python/typeshed into cleanu…
Avasam 402833a
Remove extra_description
Avasam eea4b4e
sub_commands is a ClassVar and fix overloads
Avasam 06b57f2
Merge branch 'main' into cleanup-_distutils
AlexWaygood File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,13 @@ | ||
version = "67.4.*" | ||
requires = ["types-docutils"] | ||
extra_description = """\ | ||
Having [setuptools](https://pypi.org/project/setuptools/) installed results in incorrect \ | ||
[distutils](https://docs.python.org/3/distutils/introduction.html) typing. \ | ||
`types-setuptools` makes no attempt at correcting this issue. As of \ | ||
`setuptools>=60.0.0`, you [should not be using `distutils` directly](\ | ||
https://setuptools.pypa.io/en/latest/deprecated/distutils-legacy.html). \ | ||
`distutils` is deprecated as of Python 3.10 and will be fully removed in Python 3.12. \ | ||
(see [PEP 632](https://peps.python.org/pep-0632/)) | ||
""" | ||
|
||
[tool.stubtest] | ||
ignore_missing_stub = true |
This file was deleted.
Oops, something went wrong.
This file contains 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
Empty file.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains 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
Empty file.
This file was deleted.
Oops, something went wrong.
21 changes: 0 additions & 21 deletions
21
stubs/setuptools/setuptools/_distutils/command/bdist_dumb.pyi
This file was deleted.
Oops, something went wrong.
52 changes: 0 additions & 52 deletions
52
stubs/setuptools/setuptools/_distutils/command/bdist_rpm.pyi
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure that this is necessary -- it sort of feels like it's
setuptools
's problem rather than ours. If we do want some kind of a note here, I'd prefer it if it were slightly more concise.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this look better to you? Same links, and all the same info can be found at those locations.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, the more I think about it, the more I lean towards not including this note at all. It feels like unnecessary finger-pointing at
setuptools
from us. Thedistutils
situation is very frustrating for me, a typeshed maintainer, but as far as I know we haven't received any complaints from users of our stubs about incorrectdistutils
typing, so it sort of feels like this note is attempting to solve something that may not actually be much of an issue for users. If we do get complaints or queries from users, we can maybe rethink this, but for now I think we can probably do without this :)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can see what you mean. I also expect the amount of users who'll actually land on the PyPI page to be taught about the issue of mixing setuptools and distutils together to be really small. (pyright ships stubs, and the average mypy user probably installs stubs from mypy's CLI suggestion).
I'll omit the message for now. Can be revised later if needed or if other maintainers feel differently about it.