Skip to content

Commit 1627e0e

Browse files
committed
Add PackageVersion logging
1 parent 2ad7e61 commit 1627e0e

File tree

1 file changed

+6
-0
lines changed
  • src/Microsoft.VisualStudio.ProjectSystem.Managed/ProjectSystem/PackageRestore/Snapshots

1 file changed

+6
-0
lines changed

src/Microsoft.VisualStudio.ProjectSystem.Managed/ProjectSystem/PackageRestore/Snapshots/RestoreLogger.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,12 @@ private static void LogTargetFramework(BatchLogger logger, TargetFrameworkInfo t
6161
LogReferenceItems(logger, "Project References", targetFrameworkInfo.ProjectReferences);
6262
LogReferenceItems(logger, "Package References", targetFrameworkInfo.PackageReferences);
6363
LogReferenceItems(logger, "NuGet Audit Suppressions", targetFrameworkInfo.NuGetAuditSuppress);
64+
65+
// CPM typically adds a lot of items, normally the same set for all projects in the solution, and for individual projects
66+
// many of the items aren't referenced by the project. While this is diagnostic logging, PackageVersions are particularly
67+
// spammy, so we'll only output the count for basic problem investigation, rather than the full list.
68+
logger.WriteLine($"Package Versions -- {targetFrameworkInfo.CentralPackageVersions.Length} (count only)");
69+
6470
LogProperties(logger, "Target Framework Properties", targetFrameworkInfo.Properties);
6571

6672
logger.IndentLevel--;

0 commit comments

Comments
 (0)