dev-cycles / contextive

Get on the same page.
https://contextive.tech
MIT License
244 stars 6 forks source link

Omnisharp error after installing Contextive #46

Closed msp-incom closed 1 year ago

msp-incom commented 1 year ago

Just installed Contextive from the marketplace in VS code 1.80.0 on Windows

Then ran the Contextive: Initialize Definitions

And now I get errors all the time, even hovering over stuff in the output window with

"Request textDocument/hover failed. Source: Contextive (Extension) Go to output

From Output [Error - 7:30:59 AM] Request textDocument/hover failed. Message: Internal Error - System.TimeoutException: MailboxProcessor.PostAndAsyncReply timed out. at <StartupCode$FSharp-Core>.$Mailbox.PostAndAsyncReply@471-1.Invoke(FSharpOption1 res) in D:\a_work\1\s\src\FSharp.Core\mailbox.fs:line 472 at Microsoft.FSharp.Control.AsyncPrimitives.CallThenInvokeNoHijackCheck[a,b](AsyncActivation1 ctxt, b result1, FSharpFunc2 userCode) in D:\a_work\1\s\src\FSharp.Core\async.fs:line 528 at Microsoft.FSharp.Control.Trampoline.Execute(FSharpFunc2 firstAction) in D:\a\_work\1\s\src\FSharp.Core\async.fs:line 148 --- End of stack trace from previous location --- at OmniSharp.Extensions.LanguageServer.Server.Pipelines.SemanticTokensDeltaPipeline2.Handle(TRequest request, CancellationToken cancellationToken, RequestHandlerDelegate1 next) at OmniSharp.Extensions.LanguageServer.Server.Pipelines.ResolveCommandPipeline2.Handle(TRequest request, CancellationToken cancellationToken, RequestHandlerDelegate1 next) at MediatR.Pipeline.RequestPreProcessorBehavior2.Handle(TRequest request, CancellationToken cancellationToken, RequestHandlerDelegate1 next) at MediatR.Pipeline.RequestPostProcessorBehavior2.Handle(TRequest request, CancellationToken cancellationToken, RequestHandlerDelegate1 next) at MediatR.Pipeline.RequestExceptionProcessorBehavior2.Handle(TRequest request, CancellationToken cancellationToken, RequestHandlerDelegate1 next) at MediatR.Pipeline.RequestExceptionProcessorBehavior2.Handle(TRequest request, CancellationToken cancellationToken, RequestHandlerDelegate1 next) at MediatR.Pipeline.RequestExceptionActionProcessorBehavior2.Handle(TRequest request, CancellationToken cancellationToken, RequestHandlerDelegate1 next) at MediatR.Pipeline.RequestExceptionActionProcessorBehavior2.Handle(TRequest request, CancellationToken cancellationToken, RequestHandlerDelegate1 next) at OmniSharp.Extensions.JsonRpc.RequestRouterBase1.gInnerRoute|7_0(IServiceScopeFactory serviceScopeFactory, Request request, TDescriptor descriptor, Object params, CancellationToken token, ILogger logger) at OmniSharp.Extensions.JsonRpc.RequestRouterBase1.RouteRequest(IRequestDescriptor1 descriptors, Request request, CancellationToken token) at OmniSharp.Extensions.JsonRpc.DefaultRequestInvoker.<>c__DisplayClass10_0.<b5>d.MoveNext() Code: -32603 `

chrissimon-au commented 1 year ago

Hi @msp-incom , thanks for the bug report!

I have not been able to replicate this - on windows with contextive v1.9.2 and vs code 1.8.0 it works fine for me.

Can you confirm if the issue still happens after you close and re-open vscode in the same folder?

Also, can you confirm a few details to help me diagnose:

  1. Contextive Extension Version
  2. contextive.path setting value (probably undefined, but just in case a value has been set)
  3. Disk path of the open folder (redact any private info). We did have an issue with paths with special characters in them... this was resolved a while ago, but just checking in case there's another edge case
  4. newline setting in the definitions file (e.g. CRLF or LF)

Thanks!

msp-incom commented 1 year ago

Hmm a reboot seems to have fixed it, so maybe some wrong state just after installing it :/

chrissimon-au commented 1 year ago

Thanks for confirming.

If you have time, one option is to try replicating with an 'initialize' in a fresh folder - the reason I ask is that once the file is already there, contextive is started on workspace open and loads the file immediately, compared with the 'initialise' command which starts contextive on command invocation and then loads the file when triggered by a file watcher notification once the file is created. I haven't been able to replicate the issue even when running the initialise command, but it's possible that contextive is unable to handle something in your environment but only during initialise.

Otherwise, please re-open this if it happens again for you and or anyone in your team!

msp-incom commented 1 year ago

Tried again on a new repository, same machine and this time it just worked when I initialized :/

Will report back if it happens again later :)