ionide/FsAutoComplete

0.59 SqlDataProvider not working

WillEhrendreich opened this issue · 19 comments

Hey guys!

Thanks so much for your work on this awesome community project, it's super appreciated, and you guys are fantastic for keeping the fsharp community supported, completely because you are so generous to do so.

For whatever reason, after upgraded to the 0.59 release, I get my neovim breaking.

the diagnostic message is

F# Compiler:

internal error: Method not found: 'Void Microsoft.FSharp.Core.CompilerServices.TypeProviderConfig..ctor(Microsoft.FSharp.Core.FSharpFunc`2<System.String,Boolean>, Microsoft.FSharp.Core.FSharpFunc`2<Microsoft.FSharp.Core.Unit,System.String[]>)'. [193]

aka

TypeProviderConfig(f1 : string -> bool, f2: unit -> string[])

image

Thanks for the kind words :)

Can you try to reproduce in the latest version of VS? That would help determine if the issue is in FCS specifically, or FsAutoComplete.

Separately, we don't have good coverage for type providers (especially because most of them require some live connection!) so if you know of a good, standalone script that we could use to get them into heavier testing that would help a ton. @TheAngryByrd what about using TestContainers or something for a postgres TP?

Might be related to dotnet/fsharp#13721

FSAC 0.59.0 is on FCS 43.7.200 (the stable from last week), should that fix be present there?

FSAC 0.59.0 is on FCS 43.7.200 (the stable from last week), should that fix be present there?

Yeah, this PR is there, but I believe that it's what might've caused it.

@TheAngryByrd what about using TestContainers or something for a postgres TP?

Yeah that seems possible. Will we need to test a set of different TPSDK versions (I guess those are baked into a TP so we dont have choice? I don't know that much about developing TPs)

@baronfel all good on the Visual studio side. i just updated it.

sqlprovider needing a live connection to something has been a major challenge. in fact I cannot get it to work in neovim or vscode at all if i'm not using a schema for my db connection.

I have to be within visual studio, invalidate the connection's cache, comment out the ContextSchemaPath arg, delete my schema file, then uncomment the Context schema path arg. after that, I can go into neovim and it doesn't freak out about Microsoft.Data.SqlClient not being available "on this platform"..

@WillEhrendreich Thank you for checking! We'll need to dig in more then I guess :)

or from the command line actually, i cannot even dotnet build if i don't have the schema built beforehand

@baronfel all good on the Visual studio side. i just updated it.

sqlprovider needing a live connection to something has been a major challenge. in fact I cannot get it to work in neovim or vscode at all if i'm not using a schema for my db connection.

I have to be within visual studio, invalidate the connection's cache, comment out the ContextSchemaPath arg, delete my schema file, then uncomment the Context schema path arg. after that, I can go into neovim and it doesn't freak out about Microsoft.Data.SqlClient not being available "on this platform"..

Which VS have you tested it in?

image

hey @vzarytovskii

currently 17.4.5, but it worked before i just upgraded today as well..

if you want the info or system info or whatever I can certainly do that.

Oh and back when I had Enterprise a couple of months ago it also worked there..

image

hey @vzarytovskii

currently 17.4.5, but it worked before i just upgraded today as well..

if you want the info or system info or whatever I can certainly do that.

The change didn't get in 17.4 for sure, could you please try in 17.5 or 17.6?

ill grab the prerelease then, and let ya know. :)

I don't seem to have access to 17.6, is that internal still? I have 17.5.0 preview 6 listed, which is downloading now.

Confirmed, Version 17.5.0 Preview 6.0 does not break my project.

I see, so it somehow only affecting FSAC?

bafflingly, yeah.

@WillEhrendreich did this get any better with recent updates?

@TheAngryByrd It's working for me now! I don't know what you did, but way to freaking go!