FSharpLint icon indicating copy to clipboard operation
FSharpLint copied to clipboard

MissingMethodException

Open Evangelink opened this issue 4 years ago • 4 comments

Description

Got a goldenbar on VS 2019 v 16.9.0 Preview 2.0.

<entry>
    <record>974</record>
    <time>2021/01/12 08:57:22.253</time>
    <type>Error</type>
    <source>Editor or Editor Extension</source>
    <description>System.MissingMethodException: Method not found: &apos;ParserResult`2&lt;!!0,Microsoft.FSharp.Core.Unit&gt; FParsec.CharParsers.run(Microsoft.FSharp.Core.FSharpFunc`2&lt;FParsec.CharStream`1&lt;Microsoft.FSharp.Core.Unit&gt;,FParsec.Reply`1&lt;!!0&gt;&gt;, System.String)&apos;.&#x000D;&#x000A;   at FSharpLint.Framework.Configuration.parseHint@548(String hint)&#x000D;&#x000A;   at FSharpLint.Framework.Configuration.parseHints(String[] hints)&#x000D;&#x000A;   at FSharpLint.Framework.Configuration.deprecatedAllRules@566-3.Invoke(HintConfig config)&#x000D;&#x000A;   at Microsoft.FSharp.Core.OptionModule.Map[T,TResult](FSharpFunc`2 mapping, FSharpOption`1 option) in F:\workspace\_work\1\s\src\fsharp\FSharp.Core\option.fs:line 53&#x000D;&#x000A;   at FSharpLint.Framework.Configuration.flattenConfig(Configuration config)&#x000D;&#x000A;   at FSharpLint.Application.Lint.lint(LintInfo lintInfo, FileParseInfo fileInfo)&#x000D;&#x000A;   at FSharpLint.Application.Lint.lintParsedSource(OptionalLintParameters optionalParams, ParsedFileInformation parsedFileInfo)&#x000D;&#x000A;   at FSharpLintVs.LintChecker.&lt;DoUpdateAsync&gt;d__48.MoveNext()&#x000D;&#x000A;--- End of stack trace from previous location where exception was thrown ---&#x000D;&#x000A;   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&#x000D;&#x000A;   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&#x000D;&#x000A;   at Microsoft.VisualStudio.Threading.ThreadingTools.&lt;WithCancellationSlow&gt;d__9.MoveNext()&#x000D;&#x000A;--- End of stack trace from previous location where exception was thrown ---&#x000D;&#x000A;   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&#x000D;&#x000A;   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&#x000D;&#x000A;   at FSharpLintVs.LintActionsSource.&lt;&gt;c__DisplayClass11_0.&lt;&lt;HasSuggestedActionsAsync&gt;b__0&gt;d.MoveNext()&#x000D;&#x000A;--- End of stack trace from previous location where exception was thrown ---&#x000D;&#x000A;   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&#x000D;&#x000A;   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&#x000D;&#x000A;   at Microsoft.VisualStudio.Text.Utilities.GuardedOperations.&lt;CallExtensionPointAsync&gt;d__36`1.MoveNext()&#x000D;&#x000A;--- End of stack trace from previous location where exception was thrown ---&#x000D;&#x000A;   at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)</description>
  </entry>

This repeats with the same error message around 10 times at some seconds apart.

Related information

  • Operating system: Win10
  • Branch: VS extension 0.4.1

Evangelink avatar Jan 12 '21 09:01 Evangelink

Does this happen with a non-preview (aka stable) version?

knocte avatar Jan 14 '21 03:01 knocte

I will need to install it back, will let you know.

Evangelink avatar Jan 15 '21 14:01 Evangelink

Interesting, note this repo doesn't contain a VS extension.

Looks like a missing FParsec method at runtime, do you have any other F# extensions installed? Might potentially be picking up another version of FParsec from another extension that has already loaded it

duckmatt avatar Jan 15 '21 18:01 duckmatt

Sorry for the really late reply... I have been able to run more tests and compare between machines. I can say that this is not linked to Visual Studio 2019 being preview or not (I have both on my laptop and my desktop and no problem on the desktop but problems on the laptop).

I haven't diff the sdk installed on the 2 machines but do you think it could possibly be responsible?

Regarding the extensions, I am using plenty of them but the only other F# extension is F# Formatting

Evangelink avatar Feb 20 '21 19:02 Evangelink