send onFailure callback for asyncronous exceptions
A ChangeId is added and only applied for clients with target SDK UDC and above. If the ChangeId is enabled, we will still mark the internal availability state as STATE_ERROR, but we will send onFailure callback instead. This allows for the client to get the full exception message detail. If the ChangeId is not enabled, then STATE_ERROR is still propagated to the client via onAvailabilityChanged. One other update here is that we are catching all exceptions in the async task. This resolves the case where uncaught exceptions would crash the client's VoiceInteractionService process. Test: Manually throw an exception from system service to verify callback Test: atest CtsVoiceInteractionTestCases Fixes: 280471513 Bug: 272147641 Change-Id: I316e5f545eed88e490bab2e0a052c051cc0cc94e
Loading
Please register or sign in to comment