Home

Simple F# TypeProvider code cannot run in LINQPad

edited December 2018
Say I have code like this and with nuget package FSharp.Data installed:
open FSharp.Data

[<Literal>]
let path = @"https://www.linqpad.net"
type QueryHtml = HtmlProvider<path>
let html = QueryHtml.Load(path)
This code run perfectly fine with Visual Studio, but when I run it in latest LINQPad(5.37.00), it will throws a MissingMethodException:
MissingMethodException:
Failed to find method:“Microsoft.FSharp.Control.FSharpAsync`1<System.IO.TextReader> FSharp.Data.Runtime.IO.asyncReadTextAtRuntime(Boolean, System.String, System.String, System.String, System.String, System.String)”。
I switched both "Always use built-in F# compiler" On/Off, and switched both FSharp.Data version 3.0/2.x, both throw this exception. Is there any reason or any solution for this?

Comments

Sign In or Register to comment.