fsprojects / SQLProvider

A general F# SQL database erasing type provider, supporting LINQ queries, schema exploration, individuals, CRUD operations and much more besides.
https://fsprojects.github.io/SQLProvider
Other
572 stars 146 forks source link

StackOverflow when building a .NET Standard 2.0 project #600

Closed object closed 5 years ago

object commented 5 years ago

I read a similar issue description (https://github.com/fsprojects/SQLProvider/issues/534) but is somewhat confused that SO happens in a project that only references but does not use SQLProvider. Here's what I did:

  1. Created an empty F# project (just added AssemblyInfo.fs) that target netstandard2.0
  2. Created paket.dependencies file:

version 5.153.0 source https://nuget.org/api/v2 framework: auto-detect nuget FSharp.Compiler.Tools nuget FSharp.Core nuget FSharp.Data nuget FSharp.Data.TypeProviders nuget SQLProvider group Build source https://nuget.org/api/v2 framework: auto-detect nuget FAKE ~> 4 nuget SourceLink.Fake

  1. For the project itself created paket.references file:

FSharp.Compiler.Tools FSharp.Core FSharp.Data SQLProvider

When I try to build the project, build causes StackOverflow exception.

I don't use SQLProvider in this project, so there is no need to resolve anything at design time. Why does it raise SO? And even if in this scenario I need to reference .NET FX version, how my paket.dependencies file is supposed to look?

object commented 5 years ago

I could investigate a possible fix but needs some leads what to look for.

Thorium commented 5 years ago

How about ProvidedTypes.fs (taken from Typeprovider SDK) used by wrong platform version on F# compiler..?

object commented 5 years ago

Hmm, could well be. How to verify it?

Thorium commented 5 years ago

I think this could help: https://github.com/Thorium/FSharp.TypeProviders.StarterPack/commit/df543bd4498231ac96454586aefa84e361bc9abe

Then again, the stack overflow is not the real issue here.

Thorium commented 5 years ago

Should be working in 1.1.61.