-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
QueuedInterceptorWrapper does not trigger on error, but InterceptorsWrapper does. #1683
Comments
Hey, thanks for the report. Are you willing to submit a fix in a PR? If not, can you provide an executable example which exhibits the bug? |
The issue is related to Since this kind of interceptor provides a sequential processing of each event, when you make a request returning an invalid status the |
@llfbandit How do I manually change that pending state? Is there a way to do it? |
You must use another client without your jwt interceptor. Use it also for your retry request otherwise you will be in the same situation in case of unsuccessful request. |
From your code, we don't know what's happening with your handler*, but as @llfbandit suggested, a new |
hi, @CodeFoxLk have you found the answer? |
Hi @CodeFoxLk @AlexV525 any update on this. In the latest version getting the same issue #2335 |
Package
dio
Version
5.0.0
Output of
flutter doctor -v
Dart Version
No response
Steps to Reproduce
QueuedInterceptorWrapper does not trigger an error, but InterceptorsWrapper does.
This is my code to get a refresh token. The problem is when the refresh token response returns an error status of [403]. the error function not triggering. and not execute codes under the [
_dio.post(URLEndPoints.refreshTokenRequest
] post request
but when I use InterceptorsWrapper. it working fine.
Expected Result
trigger onError function after get 403. from [ _dio.post(URLEndPoints.refreshTokenRequest........]
Actual Result
does not trigger onError function after get 403. from [ _dio.post(URLEndPoints.refreshTokenRequest........]
The text was updated successfully, but these errors were encountered: