Bug Fix for Cannot install version 1.3: DDLM package not found #4890
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.
Issue Description:
There is an issue with the installation of DDLM packages, specifically when a newer installer version (e.g., 1.6.1) is run before an older version (e.g., 1.5.7). This sequence causes the DDLM packages to not install for the older version, resulting in a "package not found" error during provisioning.
Root Cause:
Processing the DDLM package enters a conditional statement due to the stale value for GetExistingPackageIfHigherVersion (set because the singleton packages have already been processed). Consequently, the singleton package is merely re-registered, and the DDLM package is not added when older versions are executed.
Fix:
Once the higher version package has been re-registered or its status is confirmed to be okay, the value for m_existingPackageIfHigherVersion should be cleared.
Testing:
Built both a new and an older version of the installer with the fix. First ran the new version, followed by the older one, ensuring that only a single Singleton package was present. Verified that the DDLM packages, main package, and frameworks installed corresponded to each installer version.
A microsoft employee must use /azp run to validate using the pipelines below.
WARNING:
Comments made by azure-pipelines bot maybe inaccurate.
Please see pipeline link to verify that the build is being ran.
For status checks on the main branch, please use TransportPackage-Foundation-PR
(https://microsoft.visualstudio.com/ProjectReunion/_build?definitionId=81063&_a=summary)
and run the build against your PR branch with the default parameters.