mirror of
https://github.com/vector-im/element-android.git
synced 2024-11-16 02:05:06 +08:00
clean logs
This commit is contained in:
parent
3146f5209b
commit
ca2d36303c
@ -450,13 +450,13 @@ class CommonTestHelper internal constructor(context: Context, val cryptoConfig:
|
|||||||
var backoffTry = 0
|
var backoffTry = 0
|
||||||
val now = System.currentTimeMillis()
|
val now = System.currentTimeMillis()
|
||||||
while (!predicate()) {
|
while (!predicate()) {
|
||||||
Timber.w("## VALR Trial nb $backoffTry")
|
Timber.v("## retryWithBackoff Trial nb $backoffTry")
|
||||||
withContext(Dispatchers.IO) {
|
withContext(Dispatchers.IO) {
|
||||||
delay(backoff[backoffTry.coerceAtMost(backoff.size - 1)])
|
delay(backoff[backoffTry.coerceAtMost(backoff.size - 1)])
|
||||||
}
|
}
|
||||||
backoffTry++
|
backoffTry++
|
||||||
if (System.currentTimeMillis() - now > timeout) {
|
if (System.currentTimeMillis() - now > timeout) {
|
||||||
Timber.w("## VALR Trial fail")
|
Timber.v("## retryWithBackoff Trial fail")
|
||||||
onFail?.invoke()
|
onFail?.invoke()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user