-
Notifications
You must be signed in to change notification settings - Fork 651
System.MissingMethodException: Method not found: 'Void NuGet.Commands.RestoreRequest..ctor( ... )'. #1538
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
as per the second case above, I think this may have been introduced in a recent beta version, a new beta version will be available shortly, it should fix these issues. |
With
The directory does not exist. I have the following files in
|
From what I can tell from the logs shown above, the util pack msbuild taskfactory is throwing an exception in it's constructor, looking for a directory that doesn't exist: "Could not find a part of the path 'C:\Users\MichaelBisbjerg.nuget\packages\utilpack.nuget.msbuild\2.9.0\buildMultiTargeting\build\netcoreapp1.1'." @LordMike can you confirm if this is happening in the latest "4.0.1-beta1-50" release? I know @stazz made some changes so perhaps it was fixed. |
As I mentioned in the other issue, #1503, I can now run builds on my desktop where I previously had an issue. I'll report back if we see this again. |
Closing the issue as it was solved in #1503 |
A coworker got this:
His
EDITAlso from the same computer, now with full stack:
|
@stazz could you please have a look? |
The error messages
hint that for some reason the path resolution misses "one level up" step between the I have to say, I've never seen this kind of error before. :) Is there something special with the environment? Any information about the .NET SDK version or maybe some magic environment variables possibly affecting assembly resolution? |
I can't reproduce this at least with the projects that contain Looking at stack trace, it goes into The This error seems really weird to me, and my gut feeling says there is something wrong with the MSBuild properties here. I noticed that Infrastructure.props file always includes Overall, I could work out exactly what is wrong and what is going on with all the |
@stazz my coworker installed So. Everything is as intended, but we'll have the exact same issues in |
I guess the I'll check what it's like in 2.2, not sure if I'll be able to actually compile it until the next version is released on NuGet... Unless I do some pretty epic hacking. :) |
Yea, sorry about that. Hadn't checked his SDK version. From our side, the issue is minor. Once 2.2 is out, we'll re-evaluate. :) |
So what's the solution? As a user of NuGet, what do I need to update to fix this? I have .Net Core 2.2 (dotnet.exe = 2.2.300), Visual Studio 2019. I also have this warning: How do I update either the "SDK NuGet version" or something else whose version was compiled against an appropriate version of the task factory? |
@ckarras The "SDK NuGet version" is the version of NuGet that is shipped with .NET Core SDK. It is not the same as the version of the .NET Core SDK itself. I'm not maintainer of this repo, but pull request #1677 was just merged, which will invoke the tasks in such way that this kind of error is no longer even possible. I think it is supposed to be coming to version 5.0.0 of the GitVersion. |
@stazz Thanks, I got two possible solutions from this information:
For both options, the changes must be done in the project (csproj) file and in any referenced project files. |
So. This is odd. This worked a few days ago, on both Windows and Linux (ubuntu - docker), but now it works only on Linux.
We're running .NET SDK 2.1.500 (aka 2.1.6), with GitVersionTask
4.0.1-beta1-47
. Without GitVersionTask, all builds - but with it we get:Updating
UtilPack.NuGet.MSBuild
to2.9.0
gives:On an Ubuntu linux (docker), the build is fine.
The text was updated successfully, but these errors were encountered: