NuGet Packages Report Seems To Have Extraneous Packages

We upgraded to TeamCity 7.1 recently and installed the latest NuGet plugin from the JetBrains CI. Some of the statements on the new NuGet report don't seem to make sense to me. This is a report TeamCity (package names have been changed to protect the innocent, highlighting added):

Used Packages

This build used and downloaded 11 NuGet packages.
Package Name Package Version
UsedPackage1 2012.814.10
UsedPackage2 2012.821.49
UsedPackage3 2012.823.324
UsedPackage4 2012.815.24
UsedPackage5 2012.816.99


UsedPackage7 2012.822.58
UsedPackage8 2012.823.343
UsedPackage9 2012.823.551
RabbitMQ.Client 2.8.4
log4net 1.2.11

Created Packages

This build created 11 NuGet package.
Package Name Package Version
CreatedPackage 2012.823.460

Published to External NuGet Feeds

TeamCity detected and added 12 NuGet packages to the feed.
Package Name Package Version Package Source
PublishedPackage1 2012.823.294 http://nuget/
CreatedPackage 2012.823.460 http://nuget/
PublishedPackage2 2012.822.192 http://nuget/
PublishedPackage3 2012.823.90 http://nuget/
PublishedPackage4 2012.823.112 http://nuget/
PublishedPackage5 2012.823.135 http://nuget/
PublishedPackage6 2012.822.140 http://nuget/
PublishedPackage7 2012.822.136 http://nuget/
PublishedPackage8 2012.823.1687 http://nuget/
PublishedPackage9 2012.823.3788 http://nuget/
PublishedPackage10 2012.823.1090 http://nuget/
PublishedPackage11 2012.817.11189.19687 http://nuget/

Used Packages

The listing is correct and as I would expect.

Created Packages

The statement "the build created 11 NuGet package" is inaccurate. The listed package is correct. Only one pack is created and listed. This log indicates only one package created:

[13:38:00]Step 9/12: Pack (NuGet Pack) (1s)
[13:38:00][Step 9/12] Cleaning C:\TeamCity\part00\BuildAgent04\work\bd80653e902f9842\PackedNuGetPackages
[13:38:00][Step 9/12] pack: Create NuGet package from CreatedPackage\CreatedPackage.csproj (1s)
[13:38:00][pack] NuGet command: C:\TeamCity\part00\BuildAgent04\tools\NuGet.CommandLine.2.0.1234.1.nupkg\tools\NuGet.exe pack C:\TeamCity\part00\BuildAgent04\work\bd80653e902f9842\CreatedPackage\CreatedPackage.csproj -OutputDirectory C:\TeamCity\part00\BuildAgent04\work\bd80653e902f9842\PackedNuGetPackages -BasePath C:\TeamCity\part00\BuildAgent04\work\bd80653e902f9842 -Verbose -Version 2012.823.460 -Properties Configuration=Release
[13:38:00][pack] Starting: C:\TeamCity\part00\BuildAgent04\temp\agentTmp\custom_script4544001821207791838.cmd
[13:38:00][pack] in directory: C:\TeamCity\part00\BuildAgent04\work\bd80653e902f9842
[13:38:00][pack] WARNING: Option 'Verbose' has been deprecated. Use 'Verbosity' instead.
[13:38:00][pack] Attempting to build package from 'CreatedPackage.csproj'.
[13:38:00][pack] Packing files from 'C:\TeamCity\part00\BuildAgent04\work\bd80653e902f9842\CreatedPackage\bin\Release'.
[13:38:00][pack] Using 'CreatedPackage.nuspec' for metadata.
[13:38:01][pack] Found packages.config. Using packages listed as dependencies
[13:38:02][pack] Id: CreatedPackage
[13:38:02][pack] Version: 2012.823.460
[13:38:02][pack] Authors: Some Author
[13:38:02][pack] Description: This does something cool
[13:38:02][pack] Project Url: http://teamcity/viewLog.html?buildId=1289483
[13:38:02][pack] Tags: tag you are it
[13:38:02][pack] Dependencies: UsedPackage9 (� 2012.823.551)
[13:38:02][pack] Added file 'lib\net40\CreatedPackage.dll'.
[13:38:02][pack] Successfully created package 'C:\TeamCity\part00\BuildAgent04\work\bd80653e902f9842\PackedNuGetPackages\CreatedPackage.2012.823.460.nupkg'.
[13:38:02][pack] Process exited with code 0

Published To External NuGet Feeds

This seems to have lots of wrong and extraneous information. Only one package was published as part of this build, not twelve. The package that was published is correctly listed. The other listed packages were not published as part of this build. The nupkg files for the published packages don't even exist in the build agent work directory. \

We have lots of builds that produces lots of NuGet packages and we have multiple build agents on a single machine. Are wires getting crossed with other builds that may be occurring on different build agents or previously occurred on the current build agent? Is the plugin pulling this information from some other location where these libraries exist?

Here is the log entry for the publish step:

[13:38:02]Step 10/12: Publish (NuGet Publish) (3s)
[13:38:02][Step 10/12] push: Publish package PackedNuGetPackages\CreatedPackage.2012.823.460.nupkg (2s)
[13:38:02][push] NuGet command: C:\TeamCity\part00\BuildAgent04\tools\NuGet.CommandLine.2.0.1234.1.nupkg\tools\NuGet.exe push C:\TeamCity\part00\BuildAgent04\work\bd80653e902f9842\PackedNuGetPackages\CreatedPackage.2012.823.460.nupkg %%teamcity_nuget_api_key_1345743482892%% -Source http://nuget/
[13:38:02][push] Starting: C:\TeamCity\part00\BuildAgent04\temp\agentTmp\custom_script5783224065089118091.cmd
[13:38:02][push] in directory: C:\TeamCity\part00\BuildAgent04\work\bd80653e902f9842\PackedNuGetPackages
[13:38:02][push] Pushing CreatedPackage 2012.823.460 to 'http://nuget/'...
[13:38:05][push] Your package was pushed.
[13:38:05][push] Process exited with code 0

We are using a custom build of the NuGet exe from the current 2.0oob branch to fix a bug that is impacting us. I gave it the version 2.0.1234.1.
Comment actions Permalink


Thank you for feedback. I created an issue for that, let's continue discussion in the tracker.


Please sign in to leave a comment.