-
Notifications
You must be signed in to change notification settings - Fork 94
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
Warnings produced when build and packing template #387
Comments
I found a workaround to get this to work in VS. Just use the template and then copy all the The other takeaway here is that I think the design of the If you also face this, ensure that you link the source Runtime Finally,
Another, less intrusive error is on line 10272, which is a "catch all" match, but the match already is exhaustive on the DU. You can just delete that line:
|
@abelbraaksma I did a bunch of updates last week and tried this again. Quite a few warnings are produced but this sequence succeeds and the resulting nuget packages look correct. You can also switch to using the FSharp.TypeProviders.SDK nuget package if you like by editing
These are the warnings I get:
There are further warnings from
|
@abelbraaksma I've adjusted the title to reflect current state |
Description
Following the instructions here: https://fsprojects.github.io/FSharp.TypeProviders.SDK/, a bunch of things go wrong:
NUnit.Extension.TeamCityEventListener
1.0.8 which was unlistedThe good news is that, besides all these issues, using
dotnet build
ordotnet test
, the project does successfully compile and the tests pass.Repro steps
Do as in the instructions, in an empty directory run:
These commands to start:
Then update Paket and compile:
Expected behavior
No warnings and an idiomatic F# project that can be opened and edited in Visual Studio. After all, it creates a
sln
file.Actual behavior
The first warnings are from Paket:
Next is, after opening the
sln
file in VS 2022, after opening a file fromMyTypeProvider.Runtime
, I get these errors:And:
Finally, trying to build it in Visual Studio (which should, logically, be similar to
dotnet build
), fails with these messages:Known workarounds
Not sure. Maybe using VS Code instead, or Rider. Haven't tried that yet.
For getting rid of the old version of FSharp.Core, this turned out to be not so easy, as the
Paket.Restore.targets
comes with the following lines:Setting these to false only gets them overridden. I did try to override them in the
fsproj
files, and remove theFSharp.Core
references in Paket, which seems to do the trick. But after this it still won't compile.I also wanted to build in
net6.0
but that seemed to be utterly impossible and I wasn't sure what was blocking this, just too many spurious errors.Looks like quite a few of these errors are due to Paket not dealing well with Nuget packages, as explained here: fsprojects/Paket#3064. For instance, trying to reference
NUnit3TestAdapter
after updating tonet6.0
ornet5.0
, this didn't work anymore and I received the following error:Changing
netstandard2.1
tonetstandard2.0
seemed to get rid of some errors and for some reason lets me occasionally compile in VS, but then, after I open thefs
files themselves, it's mayhem again with red squigglies.Related information
This is probably also related to this Paket issue that still doesn't seem to be able to deal with the implicit FSharp.Core reference: fsprojects/Paket#3972
The text was updated successfully, but these errors were encountered: