Roslyn-analyzers: typeloadexception vs2019 16.6.2 with fxcop csharp.analysers

Created on 24 Jun 2020  路  8Comments  路  Source: dotnet/roslyn-analyzers

image

_error message : could not load type "Microsoft.CodeQuality.CSharp.Analyzers.ApiDesignGuidelines.CSharpEnumsShouldHavePluralNamesFixer" when trying to use CTRL+;_

Hi,
I have this issue even after I've updated fxcop package with : Install-Package Microsoft.CodeAnalysis.FxCopAnalyzers -version 3.3.0-beta1.20323.3
the problem is that Icannot use command CTRL+; anymore (which I use all the time for "Quick actions and refactoring") because as soon as I press CTRL+; type load exception occurs
(my activitylog files are zipped in attachement : One log file generated before installing Microsoft.CodeAnalysis.FxCopAnalyzers -version 3.3.0-beta1.20323.3 and one log file generated after installing Microsoft.CodeAnalysis.FxCopAnalyzers -version 3.3.0-beta1.20323.3

activitylog.zip

Here is my visual studio community 16.6.2 installation information:

Microsoft Visual Studio Community 2019
Version 16.6.2
VisualStudio.16.Release/16.6.2+30204.135
Microsoft .NET Framework
Version 4.8.03752

Installed Version: Community

Visual C++ 2019 00435-60000-00000-AA682
Microsoft Visual C++ 2019

ASP.NET and Web Tools 2019 16.6.948.25768
ASP.NET and Web Tools 2019

ASP.NET Core Razor Language Services 16.1.0.2020603+b3ac44798c16fff5b95dbcfe62dea84aa9a1bd72
Provides languages services for ASP.NET Core Razor.

ASP.NET Web Frameworks and Tools 2019 16.6.948.25768
For additional information, visit https://www.asp.net/

Azure App Service Tools v3.0.0 16.6.948.25768
Azure App Service Tools v3.0.0

Azure Functions and Web Jobs Tools 16.6.948.25768
Azure Functions and Web Jobs Tools

C# Tools 3.6.0-4.20251.5+910223b64f108fcf039012e0849befb46ace6e66
C# components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.

Common Azure Tools 1.10
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

Extensibility Message Bus 1.2.0 (d16-2@8b56e20)
Provides common messaging-based MEF services for loosely coupled Visual Studio extension components communication and integration.

GitHub.VisualStudio 2.11.104.25275
A Visual Studio Extension that brings the GitHub Flow into Visual Studio.

IntelliCode Extension 1.0
IntelliCode Visual Studio Extension Detailed Info

JustDecompilePackage2017 Extension 1.0
JustDecompilePackage2017 Visual Studio Extension Detailed Info

Microsoft Azure Tools 2.9
Microsoft Azure Tools for Microsoft Visual Studio 2019 - v2.9.30212.1

Microsoft Continuous Delivery Tools for Visual Studio 0.4
Simplifying the configuration of Azure DevOps pipelines from within the Visual Studio IDE.

Microsoft JVM Debugger 1.0
Provides support for connecting the Visual Studio debugger to JDWP compatible Java Virtual Machines

Microsoft Library Manager 2.1.50+g25aae5a24a.R
Install client-side libraries easily to any web project

Microsoft MI-Based Debugger 1.0
Provides support for connecting Visual Studio to MI compatible debuggers

Microsoft Visual C++ Wizards 1.0
Microsoft Visual C++ Wizards

Microsoft Visual Studio Tools for Containers 1.1
Develop, run, validate your ASP.NET Core applications in the target environment. F5 your application directly into a container with debugging, or CTRL + F5 to edit & refresh your app without having to rebuild the container.

Microsoft Visual Studio VC Package 1.0
Microsoft Visual Studio VC Package

Mono Debugging for Visual Studio 16.6.17 (9692114)
Support for debugging Mono processes with Visual Studio.

Node.js Tools 1.5.20317.1 Commit Hash:3e70368beb9630c811076c051f4c9a59b45d7c10
Adds support for developing and debugging Node.js apps in Visual Studio

NuGet Package Manager 5.6.0
NuGet Package Manager in Visual Studio. For more information about NuGet, visit https://docs.nuget.org/

Office Developer Tools for Visual Studio 16.0.30007.00
Microsoft Office Developer Tools for Visual Studio

ProjectServicesPackage Extension 1.0
ProjectServicesPackage Visual Studio Extension Detailed Info

SQL Server Data Tools 16.0.62006.03190
Microsoft SQL Server Data Tools

StylerPackage Extension 1.0
StylerPackage Visual Stuido Extension Detailed Info

Test Adapter for Boost.Test 1.0
Enables Visual Studio's testing tools with unit tests written for Boost.Test. The use terms and Third Party Notices are available in the extension installation directory.

Test Adapter for Google Test 1.0
Enables Visual Studio's testing tools with unit tests written for Google Test. The use terms and Third Party Notices are available in the extension installation directory.

TypeScript Tools 16.0.20417.2002
TypeScript Tools for Microsoft Visual Studio

Visual Basic Tools 3.6.0-4.20251.5+910223b64f108fcf039012e0849befb46ace6e66
Visual Basic components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.

Visual F# Tools 10.9.1.0 for F# 4.7 16.6.0-beta.20217.4+1c969cac25e2d38d71872efe6c8226029e42bb59
Microsoft Visual F# Tools 10.9.1.0 for F# 4.7

Visual Studio Code Debug Adapter Host Package 1.0
Interop layer for hosting Visual Studio Code debug adapters in Visual Studio

Visual Studio Container Tools Extensions (Preview) 1.0
View, manage, and diagnose containers within Visual Studio.

Visual Studio Tools for CMake 1.0
Visual Studio Tools for CMake

Visual Studio Tools for Containers 1.0
Visual Studio Tools for Containers

Visual Studio Tools for Unity 4.6.1.0
Visual Studio Tools for Unity

VisualStudio.DeviceLog 1.0
Information about my package

VisualStudio.Foo 1.0
Information about my package

VisualStudio.Mac 1.0
Mac Extension for Visual Studio

WiX Toolset Visual Studio Extension 1.0.0.4
WiX Toolset Visual Studio Extension version 1.0.0.4
Copyright (c) .NET Foundation and contributors. All rights reserved.

Workflow Manager Tools 1.0 1.0
This package contains the necessary Visual Studio integration components for Workflow Manager.

Xamarin 16.6.000.1061 (d16-6@8e68aa8)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin Designer 16.6.0.318 (remotes/origin/d16-6@66afc5421)
Visual Studio extension to enable Xamarin Designer tools in Visual Studio.

Xamarin Templates 16.6.40 (1f1466f)
Templates for building iOS, Android, and Windows apps with Xamarin and Xamarin.Forms.

Xamarin.Android SDK 10.3.1.4 (d16-6/3a10de9)
Xamarin.Android Reference Assemblies and MSBuild support.
Mono: 165f4b0
Java.Interop: xamarin/java.interop/d16-6@2cab35c
ProGuard: xamarin/proguard/master@905836d
SQLite: xamarin/sqlite/3.31.1@49232bc
Xamarin.Android Tools: xamarin/xamarin-android-tools/d16-6@bfb66f3

Xamarin.iOS and Xamarin.Mac SDK 13.18.2.1 (29c4ea7)
Xamarin.iOS and Xamarin.Mac Reference Assemblies and MSBuild support.

_Originally posted by @xavave in https://github.com/dotnet/roslyn-analyzers/issues/3770#issuecomment-649091080_

All 8 comments

For some reason, I'm not able find CSharpEnumsShouldHavePluralNamesFixer in the repository.
@mavasani, Was it deleted for some reason?

@xavave Can you check if you have installed "Microsoft CodeAnalysis 2019" VSIX extension? If so, please uninstall this extension and retry.

@mavasani it's already done as I said here https://github.com/dotnet/roslyn-analyzers/issues/3770#issuecomment-649106036 but I would like to use Microsoft CodeAnalysis 2019 when it wil be fixed

@xavave This extension is deprecated AFAIK. I don't think anything will be done to it.

@Youssef1313 thank you. is there a new extension replacing this one ? btw I 've checked what was installed on my computer : it was this 3.0.0 version https://www.nuget.org/packages/Microsoft.CodeAnalysis.Analyzers/3.0.0?_src=template but this was installed also https://marketplace.visualstudio.com/items?itemName=VisualStudioPlatformTeam.MicrosoftCodeAnalysis2019 and issue disappeared with uninstalling this last one (as proposed by @mavasani )

@xavave I think you should use the NuGet Package only and uninstall the extension.

@Youssef1313 is correct. I will work this week on getting the extension removed from the gallery and getting the documentation updated.

Closing this issue. https://github.com/dotnet/roslyn-analyzers/issues/3314 tracks the remaining work here.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

paulomorgado picture paulomorgado  路  3Comments

lgolding picture lgolding  路  4Comments

sharwell picture sharwell  路  4Comments

paulomorgado picture paulomorgado  路  3Comments

x3ntrix picture x3ntrix  路  3Comments