-
Notifications
You must be signed in to change notification settings - Fork 772
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
Registering experience of fresh build of FSharp.sln on fresh machine #17125
Comments
After a few minutes waiting, I have 848 errors. I think somehow I have "warnings as errors". Looking at #nowarn "1182" // generated code has lots of unused "parseState" but this compiler directive seems to be ignored. Which is a little odd, as I don't remember having that issue before. While the "is not accessible from code location" error is a tad worrying, you can clearly see the many "value is unused" warnings here: Could it be that the language server used in Visual Studio, when you open |
VS requires SDK to be installed where it can discover it (either part of VS itself, or globally via installer/package manager). Line 52 in 75c3558
So, not much we can really do about it. |
@vzarytovskii I have the SDK installed, but the errors are still there. It compiles fine, there are just 848 errors in the error window, and some files are almost entirely red underlined when opened. If you open the current In addition, I saw some places where warning 42 and 44 were mixed up, I'll report that separately and/or open a PR. |
I don't use windows, so can't check it. Last time I did, VisualFSharp.sln worked fine. I don't think we use just FSharp.sln. It's either VS one or FCS one. Also which vs version are you using ? |
I tried both latest RTM and latest Preview. In VSCode, you don't get the squigglies? If you were to open I just opened the NOTE: it does not show the errors unless the file is open. Does that hint at a possible cause? In the |
I do get those. They are expected, been there forever, they are warnings for me though. If you know how to fix it, good, no need for separate issue for them though.
No, not necessary. Some of those are expected. |
Ok. They flood the Error List window and show up as errors for me (even benign warnings like I'll see what I can do about them. While I can work around them, it may be confusing to first timers (or people who've been away from the source for a little while like myself). While FS0042 is a warning, this one is not, can you confirm / deny that you see that one too, @vzarytovskii? File:
Again, not blocking the build though. I believe it is an autogenerated type from this:
|
A bit hidden away, but this comment by @cartermp: #10546 (comment) hints at this I'll do some tests and see if it is easy to fix. |
I've had working installations of this repo for several years, but recently installed a new workstation and I was wondering how it would go.
It is a lot smoother than it was back in the day, but there are still some things that don't quite work as expected and/or could be improved. Mostly: doing as instructed won't "just work".
System:
First attempt
Trying to be naive:
main
, runbuild.cmd
--> successFSharp.sln
in Visual Studiodotnet tool restore
in the root --> error: "The command could not be loaded" (I assume because ofglobal.json
)Second attempt
A little less naive. I ran the following command to install .NET Preview (not in devguide.md, but there they do say you need a specific Preview version):
FSharp.sln
in Visual Studio --> less errorsfsi
,fsc
andCompiler.Service.Tests
). Sorry, forgot to copy the error.dotnet tool restore
in the root --> successThen: closed Visual Studio, reopen it again, and recompile. This time success.
Error window shows 630 errors, all of them this:
All in all, not too bad. right? I can easily work with and work around these errors, and as mentioned, it is much better than in the (far) past. But I think we can still improve.
My proposal would be something like:
Still a little surprised though that building through
build.cmd
goes fine, but building through Visual Studio does not, and requires .NET SDK Preview to be installed globally. Esp because the logs clearly show this, suggesting that it has been installed successfully:The text was updated successfully, but these errors were encountered: