Speckle/Sharp MSBuild Error

This might be a weird issue but I’ve forked speckle/sharp to have a play around with some of the code and VS won’t load any of the assemblies, keep getting MSBuild errors for the all the .csproj files.

\RevitSharedResources2020.csproj : error  : The expression "[MSBuild]::VersionGreaterThanOrEquals(latest-AllEnabledByDefault, 5.0)" cannot be evaluated. Version string was not in a correct format.  C:\Program Files\dotnet\sdk\5.0.414\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.Sdk.Analyzers.targets

I managed get around this by explicitly setting the <AnalysisLevel> in each of the .csproj files. but this seems hacky – believe this is related to this issue dotnet/msbuild/issues/5875 but honestly I’m pretty green to C# so could be wrong. Is this just an amateur user-error or is there something I’m missing?

Using VS2019, believe I have all the target frameworks installed. Putting here in case anyone else is experiencing this issue.

Hey @lukxfnz thanks for flagging this!

Most of us are on VS2022 or Rider and I haven’t come across this before. Could you try with v2022?

If necessary we can add <AnalysisLevel> to Directory.Build.props and it’ll be used by default on every project.

cc @AlanRynne

Thansk @teocomi, using VS2022 fixed this. :sweat_smile: