-
Notifications
You must be signed in to change notification settings - Fork 63
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
"No public type provider classes found" error when using dotnet cli #145
Comments
Did you add fcs.props file to your project?
dotnet/fsharp#3303
…Sent from my iPhone
On Sep 12, 2018, at 00:06, Arjen ***@***.***> wrote:
I'm trying to create an F# application using the YamlConfig type provider in the .NET Core 2.1 SDK.
The following error keeps popping up when building this solution using the dotnet CLI:
error FS3053 : The type provider 'FSharp.Configuration.ConfigTypeProvider+FSharpConfigurationProvider' reported an error : The type provider constructor has thrown an exception: Exception has been thrown by the target of an invocation. [/Staging.FSharp/DataVault.Staging.FSharp.fsproj]
FSC : warning FS3005: Referenced assembly '/root/.nuget/packages/fsharp.configuration/2.0.0-alpha2/lib/netstandard2.0/FSharp.Configuration.dll' has assembly level attribute 'Microsoft.FSharp.Core.CompilerServices.TypeProviderAssemblyAttribute' but no public type provider classes were found
A workaround on a windows machine is to use the MSBuild tool instead of the dotnet CLI. But building it on a Ubuntu machine with only .NET Core SDK installed is a different story. There is no MSBuild CLI.
I have tried to search for this issue, but I don't even understand where this issue is coming from. Is it the dotnet CLI, is it an YamlConfig type provider issue or something completely different? I'm not even sure if this is the right place to address this issue at all.
Hope somebody can shed some light on this annoying compile error.
Thanks
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
@sergey-tihon Thank you for pointing that out. I had no idea what to search for, but this is indeed the issue I have! |
Adding the fsc.props file will work, but the one linked above might not work for your environment. If you are running on a build server you probably installed the F# compiler and dotnet build tools using the Visual Studio Build Tools installer instead of a Visual Studio IDE installer. In that case you can add this PropertyGroup (check your VIsual Studio install for your environment's path)
This adds a check for the path to the FSC in the Visual Studio 2017 Build Tools.
|
I'm trying to create an F# application using the YamlConfig type provider in the .NET Core 2.1 SDK.
The following error keeps popping up when building this solution using the dotnet CLI:
A workaround on a windows machine is to use the MSBuild tool instead of the dotnet CLI. But building it on a Ubuntu machine with only .NET Core SDK installed is a different story. There is no MSBuild CLI.
I have tried to search for this issue, but I don't even understand where this issue is coming from. Is it the dotnet CLI, is it an YamlConfig type provider issue or something completely different? I'm not even sure if this is the right place to address this issue at all.
Hope somebody can shed some light on this annoying compile error.
Thanks
The text was updated successfully, but these errors were encountered: