Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NuGet package broken in Unity 2021.3.6f1 #420

Open
fdorothy opened this issue Sep 14, 2022 · 1 comment
Open

NuGet package broken in Unity 2021.3.6f1 #420

fdorothy opened this issue Sep 14, 2022 · 1 comment

Comments

@fdorothy
Copy link

I'm trying to install the NuGet package Microsoft.ML.Probabilistic.Compiler in Unity 2021.3.6f1 via NuGetForUnity (https://github.com/GlitchEnzo/NuGetForUnity). I am seeing the following errors immediately after installing:

`Library\PackageCache\com.unity.visualscripting@1.7.8\Editor\VisualScripting.Core\Platforms\AotStubWriter.cs(18,37): error CS0433: The type 'CodeStatement' exists in both 'System.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' and 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'

Library\PackageCache\com.unity.visualscripting@1.7.8\Editor\VisualScripting.Core\Platforms\AotPreBuilder.cs(31,37): error CS0433: The type 'CodeStatement' exists in both 'System.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' and 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'

Library\PackageCache\com.unity.visualscripting@1.7.8\Editor\VisualScripting.Core\Platforms\AotPreBuilder.cs(305,17): error CS0433: The type 'CodeCompileUnit' exists in both 'System.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' and 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'

Library\PackageCache\com.unity.visualscripting@1.7.8\Editor\VisualScripting.Core\Platforms\AotPreBuilder.cs(368,54): error CS0433: The type 'CodeCompileUnit' exists in both 'System.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' and 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'

Library\PackageCache\com.unity.visualscripting@1.7.8\Editor\VisualScripting.Core\Platforms\ConstructorInfoStubWriter.cs(12,37): error CS0433: The type 'CodeStatement' exists in both 'System.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' and 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'

Library\PackageCache\com.unity.visualscripting@1.7.8\Editor\VisualScripting.Core\Platforms\AccessorInfoStubWriter.cs(13,37): error CS0433: The type 'CodeStatement' exists in both 'System.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' and 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'

Library\PackageCache\com.unity.visualscripting@1.7.8\Editor\VisualScripting.Core\Platforms\FieldInfoStubWriter.cs(18,37): error CS0433: The type 'CodeStatement' exists in both 'System.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' and 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'

Library\PackageCache\com.unity.visualscripting@1.7.8\Editor\VisualScripting.Core\Platforms\MethodInfoStubWriter.cs(13,37): error CS0433: The type 'CodeStatement' exists in both 'System.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' and 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'

Library\PackageCache\com.unity.visualscripting@1.7.8\Editor\VisualScripting.Core\Platforms\MethodInfoStubWriter.cs(136,51): error CS0433: The type 'CodeBinaryOperatorType' exists in both 'System.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' and 'System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
`

It looks like the depedency Systyem.CodeDom is conflicting with the system libraries?

@tminka
Copy link
Contributor

tminka commented Sep 17, 2022

There is no conflict since .NET performs assembly unification of these assemblies. The nuget package works perfectly fine outside of Unity. So this looks like a misbehavior of Unity. Check for any binding redirects that you have defined that might be messing things up.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants