F #: Is profile 47 required for Microsoft.FSharp.Data.TypeProviders?

This is a continuation of my post yesterday . To recap, I got this error when trying to build my project:

FSC: error FS2024: static linking cannot use an assembly that targets a different profile

I consulted with some people on the F # fpchat.com channel and one of them suggested that the error might be due to the fact that I did not have profile 47 because FSharp.Data uses Profile 47. I tried to download the target package for the profile 47, but was instead redirected to the Microsoft homepage. I tried the second answer on this SO page , but that didn't work either. At the moment, I still cannot get profile 47.

I have consulted the FSharp.Data GitHub page , but I am not clear why profile 47 is needed. I am using VS2013 to compile to FSharp.Core 4.3.0.0; shouldn't be enough since the GitHub page lists it as one of the supported platforms?

I created a new project, re-added all my source files and links, and tried to rebuild. I even tried uninstalling and then reinstalling Microsoft VS, although I know this probably doesn't matter.

I think the problem is most likely related to the FSharp.Data.TypeProviders reference. The error message does not appear as I exclude the reference to FSharp.Data.TypeProviders. The weirdest thing is that I haven't changed my links at all in the last week or so, but the error message only came up yesterday.

So my questions are:

  • Do you need profile 47? If so, how can I purchase it?
  • Even if I get profile 47, wouldn't I have problems building my project since my other links are not targeting profile 47?
  • Are there any approaches that I might not have considered?
+3


source to share


1 answer


After tearing my hair out, offering many suggested solutions that I found on the internet, I found that the only way to solve the problem was to change my target framework from 4.5 to 4.0, reinstall all my links to be .NET 4.0 compatible, and then rebuild my decision. Using .NET 4.0 means that I can no longer use Microsoft.Experimental.Collections as it is only compatible with .NET 4.5. This means that I will have to rewrite all my code that uses Microsoft.Experimental.Collections, but I believe this is less evil than not being able to create my project at all.

So, to answer my own question mentioned in the title, profile 47 is not required to use FSharp.Data.TypeProviders. :-)



EDIT:

I found another solution to my problem. I created a new project (again), transferred all my source files, reinstalled all the DLLs I needed, and this time I have no problem with how I was building my project. I think Karsten (who wrote the first comment on this answer) is correct in saying that the versions were messed up in the original solution files.

0


source







All Articles