Copyright © 2026 Unity Technologies
this port was created wrongly, the fix landed in 6000.0.0b16 - so it is included in in 6.1 and 6.2
Superseded by version 6000.x
Cancelling this 2023.2 tech release issue since the support for this release has come to end of life. Cancelling this 2023.2 port case does not affect any LTS or Unity 6 Beta/Preview that remain open.
2023.1 is finished
2022.2 is finished
2022.1 is finished
Steps to reproduce:
1. Set up a project under VCS (e.g. P4) with at least one asset in it.
2. Make a script that calls EditorUtility.SetDirty() on the asset
3. Call AssetDatabase.SaveAssetIfDirty() on the asset
Actual results:
Asset is not checked out in source control
Expected results:
Asset is checked out in source control
Reproducible with versions:
2020.3 onwards (landed in 2022.1, and backported)
Not reproducible with versions:
Can’t test with versions:
Tested on (OS):
macOS, Windows
Notes:
[MenuItem("Test/Test Version Control Checkout")] private static void TestVersionControlCheckout() { var asset = LoadScriptableObject(); // load an asset asset.stringField += "_NewContent"; // make some changes EditorUtility.SetDirty(asset); // AssetDatabase.SaveAssets(); // ok, will checkout the asset AssetDatabase.SaveAssetIfDirty(asset); // not ok, will not checkout the asset }
Originally raised on the forums: https://forum.unity.com/threads/the-version-control-system-wont-checkout-changed-assets-when-using-assetdatabase-saveassetifdirty.1554779/#post-9685544
Issues you vote on will appear here