Search Issue Tracker

By Design

Votes

5

Found in

2018.4

2019.2.6f1

Issue ID

1202742

Regression

No

Editor-only AssemblyDefinition files ignores the Api Compatibility Level in player settings

Scripting

-

How to reproduce:
1. Open the "AssemblyTest.zip" project
2. Make sure the "Api Compatibility Level" is set to .Net 2.0
3. Open the generated Test.csproj via Text editing software (opening a script may be required for it to generate)
4. Search for "/System.dll"

Actual result: The referenced DLL is "Editor/Data/MonoBleedingEdge/lib/mono/4.7.1-api/System.dll".
Expected result: The referenced DLL is "Editor/Data/NetStandard/compat/2.0.0/shims/netfx/System.dll"

Reproducible with: 2018.4.14f1, 2019.2.15f1, 2019.3.0f2, 2020.1.0a15.

Notes:
- 2017.4 doesn't have the .NET 2.0 API compatibility option.

  1. Resolution Note:

    This is by design. We have A PR in docs to clarify that the setting don't apply to editor-only asmdefs / code in Editor directories: https://ono.unity3d.com/unity-extra/documentation/pull-request/124117/_/scripting/api-compatibility-level-dont-apply-to-editor

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.