Skip to content
Commit a1983356 authored by Tony Mak's avatar Tony Mak
Browse files

Increase the timeout in SystemTextClassifier to 1 minute

TetxClassifier APIs are supposed to call on a worker thread
(@WorkerThread), so there is no reason to enforce a short timeout like
2s.

We are seeing timeouts in some emulator tests.
SuggestConversationActions takes around 3s on the emulator.
I can imagine this can also happen on slow device or the input is
sufficiently long.

Also
- Fixed a bug that forgot to call callback.onFailure() when the caller
is not allowed to see the request.
- mOnServiceFailure should be @NonNull. It is important to invoke
callback.onFailure() to notify the client that the request has just
failed. Currently, there is only callsite that creates the
PendingRequest object and it is not null.

Test: atest -p external/libtextclassifier  --all-abi
Test: atest TextClassifierServiceSwapTest

Fixes: 171543321

Change-Id: I24ca3e8d116073650ecf588593fc1e4beba86a45
parent 6b634145
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment