Search Issue Tracker


Fixed in 2022.3.5f1, 2023.1.3f1, 2023.2.0a22



Found in




Issue ID




[General] "Warning CS8032 An instance of analyzer Unity.MonoScriptGenerator.MonoScriptInfoGenerator cannot be created" is printed in Error List when using Visual Studio 2022



Reproduction steps:
1. Open the attached project “CS8032_Warning”
2. Open Edit > Preferences > External Tools
3. Set External Script Editor to Microsoft Visual Studio 2022
4. In the Project window create a new C# Script
5. Open the newly created script
6. Observe the Error List

Expected result: There are no warnings
Actual result: Multiple CS8032 warnings are printed

Reproducible with: 2022.2.0a14, 2022.2.17f1, 2023.1.0b14, 2023.2.0a13
Not reproducible with: 2020.3.47f1, 2021.3.24f1, 2022.2.0a13

Reproducible on: Windows 10
Not reproducible on: macOS 13.3.1 (M1, Visual Studio for Mac 17.5.4 (build 8))

Warnings do not appear when using Rider or older Visual Studio versions
It might take a couple of seconds for Warnings to appear
Reproducible with newly created projects

Comments (7)

  1. F05F01

    Aug 08, 2023 15:44

    I have the same issue

    Unity 2022.3.4f1.0.14531
    Visual Studio Community 2022 version 17.6.5

    Any working solution?

  2. fabietto78

    Jul 12, 2023 11:11

    With the version Microsoft Visual Studio Community 2022 (64 bit) - Preview Version 17.7.0 Preview 3.0 the error no longer occurs.

  3. kaan0550

    Jun 26, 2023 04:35

    Same problem on 2022.3.3f1

  4. chunky_octopus

    Jun 16, 2023 15:27

    I have it with 2022.3.2f1 on Win11 and Rider 2019.3.4

  5. Jellyfish527

    Jun 04, 2023 20:50

    This issue is also present in 2022.3.0, using VS 2022 version 17.6.2, and the file that failed to load is present in the indicated folder. Here is the full error:
    Severity Code Description Project File Line Suppression State
    Warning CS8032 An instance of analyzer Unity.MonoScriptGenerator.MonoScriptInfoGenerator cannot be created from D:\Program Files\Unity\Editor\2022.3.0f1\Editor\Data\Tools\Unity.SourceGenerators\Unity.SourceGenerators.dll: Could not load file or assembly 'netstandard, Version=, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' or one of its dependencies. The system cannot find the file specified.. Assembly-CSharp D:\Program Files\Unity\Editor\2022.3.0f1\Editor\Data\Tools\Unity.SourceGenerators\Unity.SourceGenerators.dll 1 Active

  6. korlinga

    May 26, 2023 18:04

    I experienced the same symptom in 2022.2.19 using Visual Studio 2022 v17.6.1 on Windows 11 Pro

  7. Pvt-Noob

    May 23, 2023 09:19

    Same issue here. I checked the given path and the "missing" Unity.SourceGenerators.dll is there. I also tried starting VS with administrator privileges, doesn't work.

    Unity 2022.2.20 and Visual Studio 2022 17.6.0

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.