Sitelet https://github.com/fsprojects/Paket/issues/3091
Skip to content

Do framework conditional references in paket.references work with .NET SDK-style projects? #3091

Description

@dsyme

I've had trouble getting conditional references in paket.references working in the context of .NET SDK-style projects. Roughly speaking I had this in paket.references:

Nancy.Hosting.Self framework: net461

But I still get this error for when compiling TargetFramework=netcoreapp2.0 for a multi-targeting project:

C:\GitHub\dsyme\FSharp.Data\tests\FSharp.Data.Tests\FSharp.Data.Tests.fsproj : error NU1701: 
Package 'Nancy.Hosting.Self 2.0.0-clinteastwood' was restored using '.NETFramework,Version=v4.6.1' 
instead of the project target framework '.NETCoreApp,Version=v2.0'. This package may not be fully
compatible with your project.

I would have thought that the framework: net461 would suppress the reference for netcoreapp2.0?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions