1

Closed

Update-package Foo no longer works to update all projects

description

Trying to update all packages in a solution no longer functions. However using a specific -project target it succeeds. It also succeeds if I specifically use install and a project.

Update all
C:\Projects\FooPM> update-package System.ExtensionMethod 
update-package : 'System.ExtensionMethod' was not installed in any project. Update failed.
At line:1 char:1
+ update-package System.ExtensionMethod
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Update-Package], PackageNotInstalledException
    + FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.UpdatePackageCommand
Update -project
C:\Projects\FooPM> update-package System.ExtensionMethod -project Services
Updating 'System.ExtensionMethod' from version '2.3.0' to '2.3.1' in project 'Services'.
Removing 'System.ExtensionMethod 2.3.0' from Services.
Successfully removed 'System.ExtensionMethod 2.3.0' from Services.
Adding 'System.ExtensionMethod 2.3.1' to Services.
Successfully added 'System.ExtensionMethod 2.3.1' to Services.
Install
C:\Projects\FooPM> install-package System.ExtensionMethod
'System.ExtensionMethod 2.3.1' already installed.
Removing 'System.ExtensionMethod 2.3.0' from Domain.
Successfully removed 'System.ExtensionMethod 2.3.0' from Domain.
Adding 'System.ExtensionMethod 2.3.1' to Domain.
Successfully added 'System.ExtensionMethod 2.3.1' to Domain.
Closed Feb 23, 2013 at 12:39 AM by dotnetjunky
No repro

comments

dotnetchris wrote Feb 15, 2013 at 2:10 PM

Further information, I encountered this using the previous release of nuget, i updated to the nuget tip and it's occurring and the I updated to -PRE from the CI server (after uninstalling the latest first, then installing the CI build as per the docs).

tilovell wrote Feb 18, 2013 at 4:01 AM

@dotnetchris I think you're saying it's a breaking change in behavior between versions of NuGet. But: which version of NuGet did you notice the change in?

dotnetchris wrote Feb 18, 2013 at 1:08 PM

@tilovell I don't know what I'm saying. I expect
update-package System.ExtensionMethod 
To update every single project in my solution. It returns "not installed in any project" is just inaccurate, it's installed in nearly every project.

I can confirm it has not functioned as expected for me on 2.2, 2.1, i can't confirm which version I attempted to use this last prior to 2.1. I see 2.2.1 is released, I will uninstall the CI build and attempt with 2.2.1

dotnetchris wrote Feb 18, 2013 at 8:19 PM

Well i updated to 2.2.1 and updated project.nuget\nuget.exe and appdata\local\nuget\nuget.exe and now I have a new error

Package Manager Console Host Version 2.2.40116.9051

Type 'get-help NuGet' to see all available NuGet commands.

The schema version of 'System.ExtensionMethod' is incompatible with version 2.2.40116.9051 of NuGet. Please upgrade NuGet to the latest version from http://go.microsoft.com/fwlink/?LinkId=213942.
C:\Projects\RAMSPM> update-package System.ExtensionMethod
update-package : The schema version of 'System.ExtensionMethod' is incompatible with version 2.2.40116.9051 of NuGet. Please upgrade NuGet to the latest version from http://go.microsoft.com/fwlink/?LinkId=213942.
At line:1 char:1
  • update-package System.ExtensionMethod
  • ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    • CategoryInfo : NotSpecified: (:) [Update-Package], InvalidOperationException
    • FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.UpdatePackageCommand

dotnetchris wrote Feb 18, 2013 at 10:17 PM

Manually removing the package from all package.configs and csprojs, i released a new version that i removed the xmlns from the nuspec and that seemed to have fixed issues.

I have concerns that this could still impact others, including myself with other packages however it doesn't seem to have yet.