Finish changing versioning scheme - #60
Merged
Merged
Conversation
This change was removed from typeshed-internal#57, so as to make that PR more a refactoring. The changes here accomplish two things: First, allows us to change the specificity of how we pin versions in typeshed while ensuring that users who install without pinning versions still get the latest stub. Second, incrementing the fourth position helps disambiguate "upstream version" from "types version", reducing user confusion. See my comment here: typeshed-internal#57 (comment)
JelleZijlstra
approved these changes
Sep 23, 2022
hauntsaninja
added a commit
to hauntsaninja/typeshed
that referenced
this pull request
Sep 26, 2022
stub_uploader is developing a bunch of validation, a lot of which must live in that repo for security reasons. We don't want to find out about this validation failing when stub uploading fails. We also run it in the daily test since there are some checks that (unfortunately, albeit unlikely) can be broken by new upstream releases. This is blocked on typeshed-internal/stub_uploader#60
srittau
approved these changes
Sep 27, 2022
srittau
left a comment
Member
There was a problem hiding this comment.
Please make sure it doesn't break any of the packages that don't follow this scheme yet before merging.
Contributor
Author
|
I don't have permissions on this repo to merge, so one of you two would need to do it :-) We test that all of the asserts hold when incrementing all currently existing package versions here: stub_uploader/tests/test_integration.py Line 37 in 4588d57 I also just locally added: diff --git a/stub_uploader/get_version.py b/stub_uploader/get_version.py
index 9c5bfd1..c2c4bd7 100644
--- a/stub_uploader/get_version.py
+++ b/stub_uploader/get_version.py
@@ -139,4 +139,5 @@ def determine_incremented_version(metadata: Metadata) -> str:
version = compute_incremented_version(
metadata.version_spec, published_stub_versions
)
+ print(f"{metadata.stub_distribution:<40}\t{str(version):<12} {str(metadata.version_spec):<10} {max(published_stub_versions)}")
return str(version)and ran |
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
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.
This change was removed from #57, so as to make that PR more a refactoring. The changes here accomplish two things:
First, allows us to change the specificity of how we pin versions in typeshed while ensuring that users who install without pinning versions still get the latest stub.
Second, incrementing the fourth position helps disambiguate "upstream version" from "types version", reducing user confusion. See my comment
here: #57 (comment)
We can wait longer if we're suspicious of #57, but there have been a half dozen stub uploads since then. Please let me know if there are any tests I could add that would be worthwhile.