MSBuild fails after migration from packages.config to PackageRefence

Hi,

I have migrated all my projects within solution from packages.config to PackageReference:

https://docs.microsoft.com/en-us/nuget/consume-packages/migrate-packages-config-to-package-reference

and application itself builds just fine. TeamCity on another hand keeps failing me on the MSBuild part. Seems like my build step can't handle packages being built and misses an assembly or refence, so like package isn't actually restored.

One of the issues from build.log file:

error CS0246: The type or namespace name 'HtmlAgilityPack' could not be found (are you missing a using directive or an assembly reference?)

Here's the latest build log:

https://pastebin.com/raw/GihT2HiD

I have tried many things like some -t:Restore params but they didn't succeed.

edit://

I almost forgot! (well, I actually did). I have created a simple .NET ConsoleApp with 2 projects inside. One which contains packages.config and the other one with PackageRefence. That one builds fine on TeamCity... So I'm leaning towards the issue with ASP.NET WebForms Apps...

 

0

Please sign in to leave a comment.