unosquare/sshdeploy

Fails if project depends on a .NET standard 2.1 assembly

SvdSinner opened this issue · 1 comments

Describe the bug
Projects that have .NET Standard 2.1 dependencies fail to deploy

To Reproduce
Steps to reproduce the behavior:

  1. Create solution with a .NET 5.0 console application that has a project reference to a .NET Standard 2.1 class library
  2. From the project directory of the console application, execute "dotnet-sshdeploy push -f net50"
  3. Deployment fails with error:
    C:\Program Files\dotnet\sdk\5.0.102\Sdks\Microsoft.NET.Sdk\targets\Microsoft.PackageDependencyResolution.targets(241,5): error NETSDK1005: Assets file '<.NET Standard 2.1 project directory>\obj\project.assets.json' doesn't have a target for 'netstandard2.1'. Ensure that restore has run and that you have included 'netstandard2.1' in the TargetFrameworks for your project.
    [<.NET Standard 2.1 project .csproj file>]
    Invoking MSBuild target failed

Expected behavior
The application should successfully deploy.

Desktop (please complete the following information):

  • OS: Windows 10
stale commented

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.