zzarchive-VisualFSharpPowerTools
zzarchive-VisualFSharpPowerTools copied to clipboard
Exception in VFT's `LanguageService.VsTextColorState.GetColorStateAtStartOfLine`
trafficstars
VS 2015, just after opening VFPT solution:
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
[VFPT][Error 04:41:37 PM] Context: Exception occurs while querying lexing states.
Exception Message: Object reference not set to an instance of an object.
Stack Trace: at Microsoft.VisualStudio.FSharp.LanguageService.VsTextColorState.GetColorStateAtStartOfLine(IVsTextColorState colorState, Int32 line)
at lambda_method(Closure , IVsTextColorState , Int32 )
at FSharpVSPowerTools.ProjectSystem.VSLanguageService.buildQueryLexState(ITextBuffer textBuffer, String source, FSharpList`1 defines, Int32 line)
.............
Number of exception is huge, the output window contained > 7000 lines.
Looks like threading issue.
We haven't had this issue when Tokenize functions are called on UI thread. Do you know when this issue occurs? If it's a threading issue, it may happen quite frequently.