Skip to content
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

SDK project.assets.json - multi-target project framework being set to wrong target framework #3646

Closed
gursharan001 opened this issue Sep 5, 2019 · 1 comment

Comments

@gursharan001
Copy link

gursharan001 commented Sep 5, 2019

Description

project.assets.json lists a multi-target project as targeting net461 even though netstandard2.0 is set in project reference

Repro steps

unzip the attachment ProjectAssetsJson.zip
MSBUILD version - 16.2.37902.0

  1. go to root folder of project
  2. run .paket\paket.exe install
  3. run msbuild /t:cleanobjbins
  4. run msbuild /t:restore
  5. run msbuild /t:build

Expected behavior

TestingHost/obj/project.assets.json - Dependency-MultiTarget would have framework value as ".NETStandard,Version=v2.0"

TestngHost/bin - this folder should have

  1. Dependency-MultiTarget.dll - built for .netstandard2.0
  2. Depdendency_NetStandard.dll

Actual behavior

TestingHost/obj/project.assets.json - Dependency-MultiTarget framework is set to ".NETFramework,Version=v4.6.1"

TestngHost/bin - this folder has

  1. Dependency-MultiTarget.dll - built for .netstandard2.0 (Verified using ILSpy)
  2. Dependency_Net46.dll (should have been Dependency_NetStandard.dll)

Known workarounds

None

@gursharan001
Copy link
Author

i was able to reproduce this without using paket. Using nuget restore has similar behavior. here is a open issue on nuget - dotnet/core#2571

closing this now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant