isRetryable has false-positives

Open
#847 1 comment 2 reactions 1 assignee View on GitHub

Maintainers usually reply within 1 day

@utkrishtsahu is already working on this.

Since May 28, 2026.

Assessment

This issue has not been assessed yet.

Description

Checklist
Description

In the app we have implemented a check for isRetryable, however users report more often logouts.

A few examples of false positives in production:

iOS
AuthenticationCredentialsTokenRenewFailedException, code: RENEW_FAILED canRetry: false message: The credentials renewal failed. CAUSE: Unable to complete the operation. CAUSE: Error Domain=NSURLErrorDomain Code=-1200. (we've noticed different code value, 1001-1005, 1009 and so on)

Android
AuthenticationCredentialsUnknownException, code: An error occurred while processing the request. canRetry: false message: An error occurred while processing the request. details: {_isRetryable: false, cause: e5.b: Something went wrong, causeStackTrace: e5.b: Something went wrong at e5.a$a$a.d(Unknown Source:55) at e5.a$a$a.b(Unknown Source:0) at com.auth0.android.request.internal.e.e(Unknown Source:176) at f5.q.s(Unknown Source:291) at f5.q.k(Unknown Source:0) at f5.n.run(Unknown Source:14) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:[1154-1156]) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:[651-652]) at java.lang.Thread.run(Thread.java:[1119-1564]) Caused by: d5.b: Something went wrong at e5.a$a$a.d(Unknown Source:52) ... 8 more Caused by: javax.net.ssl.SSLHandshakeException:

Reproduction
  1. Put the phone under bad network conditions (VPN that blocks server)
  2. Try to refresh the token

Expected: isRetryable is true
Actual: isRetryable is false

Additional context

During inspection I've noticed that isRetryable fields falls back to false if not found in the details.
If we can't guarantee correctness of the data from the platform, it's probably wise to make the field nullable

auth0_flutter version

2.1.0

Flutter version

3.44.0

Platform

Android, iOS

Platform version(s)

No response

Dominant language
Dart
Stars
86
Forks
63
Avg merge
9h 33m
Merged PRs (30d)
20

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from auth0/auth0-flutter

All issues in auth0/auth0-flutter

Similar issues

More Dart issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.