Quantcast
Channel: WE MOVED to github.com/nuget. This site is not monitored!
Viewing all articles
Browse latest Browse all 7612

Edited Issue: NuGet Packages Disappearing [2411]

$
0
0
Re-Post from http://nuget.codeplex.com/discussions/361731

This is a serious issue for us and I think it needs to be created as an issue:

When I update one of our projects, references to Log4net and Rabbit MQ disappear from the csproj and packages.config file. These two libraries are needed by our logging library. The project also has packages installed that need our logging library. We have private feed that hosts all the packages we require.

At the start, the packages.config file needs version 36 of the logging library. RabbitMQ and Log4net are version 2.8.1 and 1.2.11 and there are no updates available on our feed for these packages.

I debugged through the command line update, and I see it updating logging to version 37 and then to version 38 (the latest version).

When it uninstalls version 36, I see it add an operation to uninstall Rabbit and log4net.

When version 37 is installed, I see it remove the uninstall of Rabbit and log4net.

When version 37 is uninstalled, I see it add an uninstall operation for Rabbit and log4net.

When version 38 is installed, it does not remove the uninstall operation.

I think it has something to do with the Marker. Specifically:

public void Walk(IPackage package)

{

// Do nothing if we saw this package already

if (Marker.IsVisited(package))
{
ProcessPackageTarget(package);
return;
}
...
}

When it gets to the Rabbit MQ/log4net reference, Marker.IsVisited is true and the uninstall is not removed. If I break on this and drag the cursor outside of the if statement and run the rest of the code, the Rabbit MQ / log4net uninstall operation is correctly removed.

This happens if I do a command line Install followed by an Update. It also happens if I use the Package Restore feature and then run the command line update.

It would seem the marker logic needs to be tweaked to remove the uninstall operation or the marker interaction on the uninstall side (InstallWalker.Uninstall method) needs to be tweaked to not add the uninstall operation.

This is a significant problem for our CI as it causes many builds to fail since references were removed by NuGet.

Any help is appreciated!

Viewing all articles
Browse latest Browse all 7612

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>