I modified my plugin's project file to make it behave like an mvc project. At first, it properly recognized the new imports and intellisense was working as well. However, everafter, I get the following exception just when opening a view in my plugin for the first time after launching VS and the intellisense is gone too. It's possible to fix this by repeating the proj configuration process and rebuilding the project which is obviously very tedious.. The popup on view click
Here's hopefully useful info from that file:
<entry>
<record>808</record>
<time>2020/02/11 09:18:10.198</time>
<type>Warning</type>
<source>VisualStudio</source>
<description>Error! Unable to access file (C:\Users\user\AppData\Roaming\Microsoft\VisualStudio\
15.0_0df17aac\ItemTemplatesCache\cache.bin).</description>
</entry>
<entry>
<record>809</record>
<time>2020/02/11 09:18:11.798</time>
<type>Error</type>
<source>Editor or Editor Extension</source>
<description>System.Runtime.InteropServices.COMException (0x80004005): Error HRESULT E_FAIL has been returned from a call to a COM component.
 at Microsoft.VisualStudio.Web.Interop.IVsClientBuildManagerService.DispatchUserWorkItem(IVsClientBuildManagerEventSink sink)
 at Microsoft.VisualStudio.Html.Package.CBM.CBMWorkItemDispatcher`1.Dispatch(ITextBuffer textBuffer, Func`1 toExecute, Action`1 callback)
 at Microsoft.VisualStudio.Html.Package.Razor.RazorImportsProvider.Microsoft.Html.Editor.ContainedLanguage.Razor.Def.IRazorImportsProvider.GetImportsAsync(ITextBuffer textBuffer, Func`1 toExecute, Action`1 callback)
 at Microsoft.VisualStudio.Web.Razor.Implementation.Shims.RazorCodeGenerator.DispatchGetRazorNamespacesWorkItem()
 at Microsoft.VisualStudio.Web.Razor.Implementation.Shims.RazorCodeGenerator.<.ctor>b__24_0()
 at Microsoft.Web.Editor.Utility.GuardedOperations.InvokeExtensionPoint(Object errorSource, Action action)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)</description>
</entry>
User contributions licensed under CC BY-SA 3.0