visual studio 2022 will not launch gives a JSON_RPC connection erro

ken muir 0 Reputation points
2023-03-14T12:36:15.6333333+00:00

I installed Visual Studio 2022 a week ago and it worked for 1 day. It then started to go give the following error when I launched it;

'could not start visual studio due to an error. streamJsonRpc.ConnectionLostException. The JSON_RPC connection with the remote party was lost before the reuqest could compelete.'

I removed all VPN's, virus protection software, old Visual Studios files etc. I have repaired/reinstalled Visual Studio svereal times but still get the same message. Any suggestions would be welcom

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,594 questions
Visual Studio Setup
Visual Studio Setup
Visual Studio: A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.Setup: The procedures involved in preparing a software program or application to operate within a computer or mobile device.
962 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Anna Xiu-MSFT 25,551 Reputation points Microsoft Vendor
    2023-03-15T03:24:14.86+00:00

    Hi @ken muir

    Welcome to Microsoft Q&A! 

    Please go to %userappdata%\temp\servicehub\logs and check the generated logs.

    Like this:

    Error : Exception: System.IO.FileLoadException: Could not load file or assembly 'System.Numerics.Vectors, Version=4.1.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

     

    You can close all running VS instances and try editing your config files. 

    1. Go to C:\Program Files\Microsoft Visual Studio\2022\version\Common7\IDE and edit the devenv.exe.config file:
    <dependentAssembly>
              <assemblyIdentity name="System.Numerics.Vectors" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
              <bindingRedirect oldVersion="0.0.0.0-4.1.4.0" newVersion="4.1.4.0" />
            </dependentAssembly>
    
    
    1. Go to C:\Program Files\Microsoft Visual Studio\2022\version\Common7\ServiceHub\Services\Microsoft.Developer.IdentityService and edit Microsoft.Developer.IdentityService.dll.config file:
    <dependentAssembly>
            <assemblyIdentity name="System.Numerics.Vectors" culture="neutral" publicKeyToken="b03f5f7f11d50a3a" />
            <bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0" />
          </dependentAssembly>
    
    
    1. If it doesn’t work, please try to remove the older version of System.Memory.dll in the GAC via an elevated Developer Command Prompt for VS 2022:

    gacutil /u "System.Memory, Version=4.0.1.1"

    Sincerely,

    Anna


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment". 
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

     

    1 person found this answer helpful.