Skip to content

[5.6] make package.resolved more deterministic in edge cases (#3967) #3979

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

Merged
merged 1 commit into from
Jan 6, 2022

Conversation

tomerd
Copy link
Contributor

@tomerd tomerd commented Jan 6, 2022

5.6 cherry pick of #3967

motivation: in some cases like two URLs with casing differences, package.resolved could be non-deterministic

changes:
* base managed dependencies lookup on canonical location (case insensitive, ignore .git suffix)
* refactor how package.resolved is saved to test for non material differences
* adjust call sites that manipulate the pin store to be more efficient about when to save the resolved file
* add warning when expected dependency that should be stored in the resolved file is not found
* rename CanonicalPackageIdentity as CanonicalPackageLocation and use it to compare locations where required
* rename LegacyPackageIdentity as PackageIdentityParser and simplify how identity parsing is wired (removed unusued complexity)
* adjust call sites
* add and adjust test
@tomerd tomerd added ready Author believes the PR is ready to be merged & any feedback has been addressed 5.6 labels Jan 6, 2022
@tomerd
Copy link
Contributor Author

tomerd commented Jan 6, 2022

@swift-ci please test

@tomerd tomerd merged commit bc760c3 into swiftlang:release/5.6 Jan 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready Author believes the PR is ready to be merged & any feedback has been addressed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants