This updates the dependency handling of packages to use availablePackages when a package from the same source satisfies the dependency. This improves packages that have dependencies with many versions available, and allows less data being requested from servers in the case we have already have available packages from the source.
Without this fix, the installation will be delayed with repeated resolution of the same package dependencies.
Motivation and Context
Installation of packages with many dependent versions available without reducing repeat calls to ResolvePackages
Run GeneratePackages.ps1. This will generate a single package for package-a, package-b, and package-c. It will generate 1000 packages each for package-d and package-e.
Clone and checkout the branch associated with this PR.
Build chocolatey.console.
Run choco upgrade package-a --yes --source <path-to-demo-projects>
See that install/upgrade completes within seconds.
Repeat test with delivered chocolatey 2.3 and see that the install takes much longer.
Operating Systems Testing
Windows 10
Change Types Made
[x] Bug fix (non-breaking change).
[ ] Feature / Enhancement (non-breaking change).
[ ] Breaking change (fix or feature that could cause existing functionality to change).
Description Of Changes
This updates the dependency handling of packages to use availablePackages when a package from the same source satisfies the dependency. This improves packages that have dependencies with many versions available, and allows less data being requested from servers in the case we have already have available packages from the source.
Without this fix, the installation will be delayed with repeated resolution of the same package dependencies.
Motivation and Context
Installation of packages with many dependent versions available without reducing repeat calls to ResolvePackages
Testing
choco upgrade package-a --yes --source <path-to-demo-projects>
Repeat test with delivered chocolatey 2.3 and see that the install takes much longer.
Operating Systems Testing
Change Types Made
Change Checklist
Related Issue
Fixes #3451