dotnet/buildtools

UpdateToRemoteDependencies doesn't handle OrchestratedBuildDependencyInfo when updating CurrentRefs

dagood opened this issue · 0 comments

I missed this when I added OrchestratedBuildDependencyInfo:

// Update CurrentRef for each applicable build info used.
if (!string.IsNullOrEmpty(CurrentRefXmlPath))
{
foreach (ITaskItem item in updateResults.UsedInfos
.OfType<TaskItemBuildDependencyInfo>()
.Distinct()
.Select(info => info.SourceItem)
.Where(item => !string.IsNullOrEmpty(item.GetMetadata(CurrentRefMetadataName))))
{
UpdateProperty(
CurrentRefXmlPath,
$"{item.ItemSpec}{CurrentRefMetadataName}",
versionsCommitHash);
}
}

This causes auto-updates to not update the CurrentRef. Auto-update to latest still works, but UpdateDependencies and VerifyDependencies will be stuck at whatever version CurrentRef was at.