Unity-Technologies / ProjectAuditor

Project Auditor is an experimental static analysis tool for Unity Projects.
Other
806 stars 66 forks source link

Assembly not showing #86

Closed archer-tate closed 2 years ago

archer-tate commented 2 years ago

Describe the bug After running analyze, I don't see Assembly-CSharp in the list of assemblies which means I don't don't see an analysis on my code. What I do see are all the assemblies for the various packages that I have installed.

I created an assembly for my code and re-ran the analysis. The assembly that I created also does not show up in the list.

To Reproduce Steps to reproduce the behavior:

  1. Click analyze
  2. Only assemblies for my packages are shown

Expected behavior I can see an analysis on my code as well as the packages I have installed.

Screenshots NDA

Information (please complete the following information):

mtrive commented 2 years ago

Hi @archer-tate, thanks for the report. I am now trying to reproduce this issue on my side.

Thanks, Marco

archer-tate commented 2 years ago

Hi,

  1. Yes I have many C# files under Assets which should be compiled into Assembly-CSharp.
  2. In Assemblies view and Filters I only saw the assemblies for packages. Since creating this issue, I was able to create an assembly definition in the assets folder which was recognized by Project Auditor, but only in certain cases. I created 5 assembly definitions in various folders with Assets. 2 of them were detected by Project Auditor the rest were not.
mtrive commented 2 years ago

Hi,

  1. Yes I have many C# files under Assets which should be compiled into Assembly-CSharp.
  2. In Assemblies view and Filters I only saw the assemblies for packages. Since creating this issue, I was able to create an assembly definition in the assets folder which was recognized by Project Auditor, but only in certain cases. I created 5 assembly definitions in various folders with Assets. 2 of them were detected by Project Auditor the rest were not.

Do you get any compilation error in the Summary view? Like this

summary

Does any package that Assembly-CSharp scripts depend on fails to compile?

archer-tate commented 2 years ago

Yes, I do see compilation errors in the analysis overview....however the Unity console does not show any compilation errors and the program runs just fine.

image

archer-tate commented 2 years ago

Ok, good news. Your previous message lead to to figure out what was going on. I changed platforms from UWP to Windows standalone which cleared up all of the compilation errors. Now I can see assembly-csharp. Thanks!

mtrive commented 2 years ago

FYI - I found that Assemblies with dependencies that failed to compile, where not reported in the Assemblies view. Let's say you have AssemblyA and AssemblyB, where AssemblyA depends on AssemblyB. If AssemblyB fails to compile, AssemblyA would not show up (because it's not compiled). This should be fixed now.