JetBrains / resharper-unity

Unity support for both ReSharper and Rider
Apache License 2.0
1.21k stars 131 forks source link

Errors during installation/update, freezes VS #2412

Closed OrionFive closed 11 months ago

OrionFive commented 11 months ago

This is regarding version 2023.1.0.150.

When I update or install it, there are 5 errors. Ever since this update, Visual Studio freezes up regularly.

Error log:

Install completed with 5 errors.
  11:39:23.735 ReSharperPlatformVs17_b3531ec6: Error resolving type JetBrains.ReSharper.Psi.ILanguageCppZone from assembly “JetBrains.ReSharper.Cpp, Version=777.0.0.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325”, request originating from assembly “JetBrains.ReSharper.Plugins.Unity.Shaders, Version=2023.1.0.150, Culture=neutral, PublicKeyToken=0f46ab053645825e”. Could not find a referenced assembly by the TT_ASSEMBLYREF token.
  11:39:23.775 ReSharperPlatformVs17_b3531ec6: Error resolving type JetBrains.ReSharper.Feature.Services.Cpp.CodeStyle.ICppCustomFormattingInfoProvider from assembly “JetBrains.ReSharper.Feature.Services.Cpp, Version=777.0.0.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325”, request originating from assembly “JetBrains.ReSharper.Plugins.Unity.Shaders, Version=2023.1.0.150, Culture=neutral, PublicKeyToken=0f46ab053645825e”. Could not find a referenced assembly by the TT_ASSEMBLYREF token.
  11:39:23.782 ReSharperPlatformVs17_b3531ec6: Error resolving type JetBrains.ReSharper.Feature.Services.Cpp.CodeStyle.ICppCodeFormatterExtension from assembly “JetBrains.ReSharper.Feature.Services.Cpp, Version=777.0.0.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325”, request originating from assembly “JetBrains.ReSharper.Plugins.Unity.Shaders, Version=2023.1.0.150, Culture=neutral, PublicKeyToken=0f46ab053645825e”. Could not find a referenced assembly by the TT_ASSEMBLYREF token.
  11:39:23.795 ReSharperPlatformVs17_b3531ec6: The type “JetBrains.ReSharper.Psi.ILanguageCppZone, JetBrains.ReSharper.Cpp, Version=777.0.0.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325” is not a module zone because it does not derive from the JetBrains.Application.BuildScript.Application.Zones.IZone interface.
  11:39:23.968 ReSharperPlatformVs17_b3531ec6: The type “JetBrains.ReSharper.Psi.ILanguageCppZone, JetBrains.ReSharper.Cpp, Version=777.0.0.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325” is not a module zone because it does not derive from the JetBrains.Application.BuildScript.Application.Zones.IZone interface.

Products before install
  ReSharperPlatformVs17_b3531ec6 (Wave=231 VS=17.0 Id=b3531ec6)
    ReSharper 2023.1.2 (231.0.20230515.130734)
    JetBrains.DPA.Ide.VisualStudio (231.0.20230515.132205)
  [VS not found] ReSharperPlatformVs16_43cbd73d (Wave=212 VS=16.0 Id=43cbd73d)
    ReSharper 2021.2.2 (212.0.20211006.175706)
    JetBrains.DPA.Ide.VisualStudio (212.0.20211008.82359)
    JetBrains Unity 2021.2.1.144 (UnknownCompatibility)
  [VS not found] ReSharperPlatformVs17_026a90c1 (Wave=222 VS=17.0 Id=026a90c1)
    ReSharper 2022.2.3 (222.0.20220901.64753)
    JetBrains.DPA.Ide.VisualStudio (222.0.20220901.65937)
    JetBrains Unity 2022.2.3.162 (Compatible)
Install targets
  update  ReSharperPlatformVs17_b3531ec6 at C:\Users\...\AppData\Local\JetBrains\Installations\ReSharperPlatformVs17_b3531ec6_001
Products after install
  ReSharperPlatformVs17_b3531ec6 (Wave=231 VS=17.0 Id=b3531ec6)
    ReSharper 2023.1.2 (231.0.20230515.130734)
    JetBrains.DPA.Ide.VisualStudio (231.0.20230515.132205)
    JetBrains Unity 2023.1.0.150 (Compatible)
  [VS not found] ReSharperPlatformVs16_43cbd73d (Wave=212 VS=16.0 Id=43cbd73d)
    ReSharper 2021.2.2 (212.0.20211006.175706)
    JetBrains.DPA.Ide.VisualStudio (212.0.20211008.82359)
    JetBrains Unity 2021.2.1.144 (UnknownCompatibility)
  [VS not found] ReSharperPlatformVs17_026a90c1 (Wave=222 VS=17.0 Id=026a90c1)
    ReSharper 2022.2.3 (222.0.20220901.64753)
    JetBrains.DPA.Ide.VisualStudio (222.0.20220901.65937)
    JetBrains Unity 2022.2.3.162 (Compatible)

Environment
  Windows 10 Pro 22H2, build 19045.3208, Professional, Client (Microsoft Windows NT 10.0.19045.0)
  Microsoft .NET Framework 4.8.04084 Release 528372
  OS Architecture: X64 (windows-x64)
  Time zone: (UTC+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna. Local time: 21/07/2023 11:41:18. UTC: 21/07/2023 09:41:18
  Input languages: en-US (United States-International), de-DE (German), nl-NL (United States-International), en-GB (United States-International). Default: en-US (United States-International)
  Elevation flags: 0x07 (UAC_ENABLED, VIRTUALIZATION_ENABLED, INSTALLER_DETECTION_ENABLED)
  Elevation type: 3 (TokenElevationTypeLimited)
  Global memory: TotalPhysical: 31,9GB; AvailablePhysical: 18,1GB (Load: 43%); TotalVirtual: 128TB; AvailableVirtual: 128TB; TotalPageSize: 63,9GB; AvailablePageFile: 36,9GB
  Process memory: WorkingSet: 1,34GB (Peak: 1,85GB); PageFile: 1,32GB (Peak: 1,72GB); PrivateUsage: 1,32GB; PagedPoolUsage: 1,01MB (Peak: 1,61MB); NonPagePoolUsage: 134KB (Peak: 210KB)
  ProcessorCount: 16; ProcessAffinityMask: 0xFFFF; SystemAffinityMask: 0xFFFF
  Install folder: free 551GB of 931GB
Visual Studio
  17.0_b3531ec6: Visual Studio Community 2022, Version 17.6.1 (17.6.33717.318) (Nickname="" Preview=False Incomplete=False)
Installer
  Wave: 231
  Identity: 231.0.20230517.115502
  Gallery: Local disk package gallery
  Per-machine: False
  Run as administrator: False
  Raw command line: /HostsToReInstall=ReSharperPlatformVs17_b3531ec6
  Parsed options: /HostsToReInstall=ReSharperPlatformVs17_b3531ec6
citizenmatt commented 11 months ago

The ReSharper plugin requires ReSharper C++ to be installed, as the shader HLSL support is based on the C/C++ tooling. Unfortunately, ReSharper doesn't have a way to handle optional dependencies, so you get this error in the installer. Please try and add ReSharper C++ to the product install and see if this helps.

That said, I'm not sure if it will help with freezes - I wouldn't expect VS to freeze if C++ support wasn't available. If it continues after ReSharper C++ has been added, please try and get a profiling trace of what Visual Studio is doing at that time. There are instructions here, either using the embedded profiling diagnostics (which might be tricky if VS is already hung, but useful if you can repro the situation), or by using the standalone dotTrace profiler. With a profiler snapshot, it's easier to follow the instructions and upload it to JetBrains directly, rather than try to attach to a GitHub issue, so I'm going to close this issue for now. Feel free to add the new issue number as a comment, and I can follow up further.

OrionFive commented 11 months ago

Thanks. Installing the C++ version did fix the installation errors. I guess I'll remember until next time I update Resharper, when I'll wonder why the C++ version is installed, remove it, and repeat this cycle.

I haven't had any more freezes. Either it solved it, or it was unrelated and just a fluke.