InputSystem
InputSystem copied to clipboard
[Mac Editor] Error on first play
Editor on macOS, Unity 2018.3.0b1
On first play, exceptions are thrown:
Could not re-recreate input device 'Apple Inc. Apple Internal Keyboard / Trackpad (HID)' with layout 'HID::Apple Inc. Apple Internal Keyboard / Trackpad' and variants 'Default' after domain reload
UnityEngine.Experimental.Input.LowLevel.<>c__DisplayClass6_0:<set_onUpdate>b__0(NativeInputUpdateType, Int32, IntPtr)
UnityEngineInternal.Input.NativeInputSystem:NotifyUpdate(NativeInputUpdateType, Int32, IntPtr) (at /Users/builduser/buildslave/unity/build/Modules/Input/Private/Input.cs:91)
ArgumentException: Cannot find layout matching device description 'Apple Inc. Apple Internal Keyboard / Trackpad (HID)'
Parameter name: description
UnityEngine.Experimental.Input.InputManager.AddDevice (UnityEngine.Experimental.Input.Layouts.InputDeviceDescription description, System.Boolean throwIfNoLayoutFound, System.Int32 deviceId, UnityEngine.Experimental.Input.InputDevice+DeviceFlags deviceFlags) (at Packages/com.unity.inputsystem/InputSystem/InputManager.cs:887)
UnityEngine.Experimental.Input.InputManager.RestoreDevicesAfterDomainReload () (at Packages/com.unity.inputsystem/InputSystem/InputManager.cs:2680)
UnityEngine.Experimental.Input.LowLevel.<>c__DisplayClass6_0:<set_onUpdate>b__0(NativeInputUpdateType, Int32, IntPtr)
UnityEngineInternal.Input.NativeInputSystem:NotifyUpdate(NativeInputUpdateType, Int32, IntPtr) (at /Users/builduser/buildslave/unity/build/Modules/Input/Private/Input.cs:91)
This is probably on domain unload, to be more precise
Yup, that one has starting popping recently and indeed, happens on domain reload. Functionally, other than being annoying, it should not have an impact on the usability of the system. The HID here isn't actively used by the system and should probably be suppressed entirely. Still, the problem itself needs fixing. From what I've gather so far, some HIDs end up sometimes failing system calls asking for their descriptors.
I don't see this happen on Develop anymore.