Search Issue Tracker

Fixed

Votes

0

Found in

6000.4.0a2

6000.4.0a4

Issue ID

UUM-125291

Regression

Yes

Input Actions asset gets corrupted when upgrading a project

-

 

Input Actions asset gets corrupted when upgrading a project

Steps to reproduce:

  1.  Open attached project “project-blobario.zip” on 6000.4.0a1
  2.  Observe in Assets > InputSystem > PlayerControls.inputactions file is imported correctly
  3.  Delete the project
  4. Open the project on 6000.4.0a2 or later
  5. Observe in Assets > InputSystem > PlayerControls.inputactions file is not correctly imported

Actual results: 
Seems like input actions import schedule has changed and now get corrupted during project upgrade if other upgrades like URP Material Upgrade interupt the upgrade process

Failed input action asset import produces the following error:

Asset import failed, "Assets/InputSystem/PlayerControls.inputactions" > UnityException: Calls to "AssetDatabase.ImportAsset" are restricted during asset importing. Please make sure this function is not called from ScriptedImporters or PostProcessors, as it is a source of non-determinism.
UnityEditor.AssetDatabase.ImportAsset (System.String path, UnityEditor.ImportAssetOptions options) (at <04214431283b4a3d96b2fe1a4357a80f>:0)
UnityEditor.AssetDatabase.ImportAsset (System.String path) (at /Users/bokken/build/output/unity/unity/Modules/AssetDatabase/Editor/ScriptBindings/AssetDatabase.bindings.cs:341)
UnityEngine.InputSystem.Editor.InputActionImporter.GenerateWrapperCode (UnityEditor.AssetImporters.AssetImportContext ctx, UnityEngine.InputSystem.InputActionAsset asset, System.String codeNamespace, System.String codeClassName, System.String codePath) (at ./Library/PackageCache/com.unity.inputsystem@85cf3259697c/InputSystem/Editor/AssetImporter/InputActionImporter.cs:274)
UnityEngine.InputSystem.Editor.InputActionImporter.OnImportAsset (UnityEditor.AssetImporters.AssetImportContext ctx) (at ./Library/PackageCache/com.unity.inputsystem@85cf3259697c/InputSystem/Editor/AssetImporter/InputActionImporter.cs:132)
UnityEditor.AssetImporters.ScriptedImporter.GenerateAssetData (UnityEditor.AssetImporters.AssetImportContext ctx) (at /Users/bokken/build/output/unity/unity/Modules/AssetPipelineEditor/Public/ScriptedImporter.cs:25)

(Filename: ./Modules/AssetPipelineEditor/Public/ScriptedImporter.cpp Line: 216)

Expected results: 
Input Action assets is imported correctly when upgrading the project

Reproducible with versions: 
6000.4.0a2, 6000.4.0a4

Not reproducible with versions: 
6000.0.61f1, 6000.2.10f1, 6000.3.0b8, 6000.4.0a1

Tested on (OS): 
MacOS Sequoia 15.7.1

Notes:

  •  Reimporting the input actions asset fixes the issue

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.