vscode-python: Language Server: System.ObjectDisposedException: PriorityProducerConsumer`1 instance is disposed

Latest Insiders vscode-pythong: 2018.8.0-alpha1

creating a new class the language server produced following to OUtput.

[Info - 7:14:27 AM] Found 28 completions for file:///p:/perforce_Playground/derekw_de02-1777_rce_dev/del.py at (13, 17) after filtering [Error - 7:14:29 AM] System.ObjectDisposedException: PriorityProducerConsumer1 instance is disposed Object name: 'PriorityProducerConsumer1’. at Microsoft.PythonTools.Analysis.Infrastructure.DisposeToken.ThrowIfDisposed() at Microsoft.PythonTools.Analysis.Infrastructure.PriorityProducerConsumer`1.Produce(T value, Int32 priority) at Microsoft.PythonTools.Intellisense.AnalysisQueue.Enqueue(IAnalyzable item, AnalysisPriority priority) at Microsoft.PythonTools.Analysis.LanguageServer.Server.OnDocumentChangeProcessingComplete(IDocument doc, VersionCookie vc, Boolean enqueueForAnalysis, AnalysisPriority priority, IDisposable disposeWhenEnqueued)

Code when crash happened image

Outline is all wrong at the crash point. image

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Comments: 15 (2 by maintainers)

Most upvoted comments

Still seeing this with the 2018.8.0 release (please reopen):

[Error - 11:39:04 AM] System.ObjectDisposedException: PriorityProducerConsumer`1 instance is disposed
Object name: 'PriorityProducerConsumer`1'.
   at Microsoft.PythonTools.Analysis.Infrastructure.DisposeToken.ThrowIfDisposed()
   at Microsoft.PythonTools.Analysis.Infrastructure.PriorityProducerConsumer`1.Produce(T value, Int32 priority)
   at Microsoft.PythonTools.Analysis.LanguageServer.Server.OnDocumentChangeProcessingComplete(IDocument doc, VersionCookie vc, Boolean enqueueForAnalysis, AnalysisPriority priority, IDisposable disposeWhenEnqueued)

It’s pretty annoying as it opens the output panel every few minutes while typing.