VS 2017 crashes when linting a Javascript file
Closed this issue · 3 comments
Installed product versions
- Visual Studio: 2017 Enterprise 15.6.x
- This extension: 1.1.47
Description
When attempting to save a Javascript file, Visual Studio Crashes, If you go into the debugger, it states
System.IO.FileNotFoundException
HResult=0x80070002
Message=Could not load file or assembly 'Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The system cannot find the file specified.
Source=VisualLinter
StackTrace:
at jwldnr.VisualLinter.Linting.Linter.d__1.MoveNext() in C:\projects\visuallinter\src\VisualLinter\Linting\Linter.cs:line 90
at System.Runtime.CompilerServices.AsyncTaskMethodBuilder.Start[TStateMachine](TStateMachine& stateMachine)
at jwldnr.VisualLinter.Linting.Linter.LintAsync(ILinterProvider provider, String filePath, CancellationToken token)
at jwldnr.VisualLinter.Tagging.TaggerProvider.d__20.MoveNext() in C:\projects\visuallinter\src\VisualLinter\Tagging\TaggerProvider.cs:line 176
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at jwldnr.VisualLinter.Tagging.LinterTagger.d__25.MoveNext() in C:\projects\visuallinter\src\VisualLinter\Tagging\LinterTagger.cs:line 104
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at jwldnr.VisualLinter.Tagging.LinterTagger.d__30.MoveNext() in C:\projects\visuallinter\src\VisualLinter\Tagging\LinterTagger.cs:line 158
at System.Runtime.CompilerServices.AsyncMethodBuilderCore.<>c.b__6_0(Object state)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
at System.Windows.Threading.DispatcherOperation.InvokeImpl()
at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(Object state)
at MS.Internal.CulturePreservingExecutionContext.CallbackWrapper(Object obj)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at MS.Internal.CulturePreservingExecutionContext.Run(CulturePreservingExecutionContext executionContext, ContextCallback callback, Object state)
at System.Windows.Threading.DispatcherOperation.Invoke()
at System.Windows.Threading.Dispatcher.ProcessQueue()
at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
As a workaround, installing Newtonsoft.Json 10.0.2 in the GAC resolves the issue
Hi @ChristineBoersen, and thanks for the report.
I've seen this issue with other assemblies as well. I'm not sure its related but I'll have to take a look..
I've tried addressing this issue by adding Newtonsoft.Json
as an asset.
I'll go ahead and close this issue but if updating the extension to v1.1.59
does not work for you, post back here and I'll reopen this issue.