Skip to content
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

Allow non-types dependencies #5769

Merged
merged 1 commit into from
Jul 14, 2021
Merged

Conversation

srittau
Copy link
Collaborator

@srittau srittau commented Jul 13, 2021

Remove the check in check_consistency that ensures that only other
type packages from typeshed are being depended on. Instead, add an
explanation to CONTRIBUTING that spells out the requirements. This
adds a higher, but reasonable burden on maintainers to check the
dependencies manually.

Part of #5768

Remove the check in check_consistency that ensures that only other
type packages from typeshed are being depended on. Instead, add an
explanation to CONTRIBUTING that spells out the requirements. This
adds a higher, but reasonable burden on maintainers to check the
dependencies manually.

Part of python#5768
Copy link
Contributor

@JukkaL JukkaL left a comment

Choose a reason for hiding this comment

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

I agree that this is a good idea. The old rules are too restrictive as more projects will be bundling types/stubs.

@hauntsaninja
Copy link
Collaborator

We could check that we depend on the types version of a distribution if one exists (assert not ("types-" + dep) in known_distributions), might catch some silly errors.

@Akuli
Copy link
Collaborator

Akuli commented Jul 13, 2021

We could also check that if the package name starts with types-, then there's corresponding third-party package in typeshed. Basically the checks that were deleted, but only for types-foo packages. Even though anyone can publish a package named types-foo that could be useful to depend on, this could catch typos.

@srittau
Copy link
Collaborator Author

srittau commented Jul 13, 2021

@hauntsaninja That could actually be counter-productive when transitioning from typeshed stubs to built-in stubs. For example, stubs depending on cryptography should not depend on the (obsolete, Python 2) types package.

@srittau srittau merged commit ad3f0c8 into python:master Jul 14, 2021
@srittau srittau deleted the non-type-dependencies branch July 14, 2021 12:29
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.

5 participants