Skip to content
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

Error on redirect from the browser #101

Closed
isgj opened this issue Jul 4, 2019 · 1 comment
Closed

Error on redirect from the browser #101

isgj opened this issue Jul 4, 2019 · 1 comment

Comments

@isgj
Copy link

isgj commented Jul 4, 2019

After a successful login the browser tries to redirect to the flutter app. On some emulators it works, on one that has a default browser it errors.
Android 6 (API 23).

Here are the logs:

I/flutter ( 5737): Bad state: Future already completed
E/flutter ( 5737): [ERROR:flutter/lib/ui/ui_dart_state.cc(148)] Unhandled Exception: Bad state: Future already completed
E/flutter ( 5737): #0      _Completer.completeError  (dart:async/future_impl.dart:21:31)
E/flutter ( 5737): #1      Authenticator.onError 
package:simple_auth/…/api/authenticator.dart:38
E/flutter ( 5737): #2      SimpleAuthFlutter.init.<anonymous closure> 
package:simple_auth_flutter/simple_auth_flutter.dart:76
E/flutter ( 5737): #3      _rootRunUnary  (dart:async/zone.dart:1132:38)
E/flutter ( 5737): #4      _CustomZone.runUnary  (dart:async/zone.dart:1029:19)
E/flutter ( 5737): #5      _CustomZone.runUnaryGuarded  (dart:async/zone.dart:931:7)
E/flutter ( 5737): #6      _BufferingStreamSubscription._sendData  (dart:async/stream_impl.dart:336:11)
E/flutter ( 5737): #7      _BufferingStreamSubscription._add  (dart:async/stream_impl.dart:263:7)
E/flutter ( 5737): #8      _ForwardingStreamSubscription._add  (dart:async/stream_pipe.dart:132:11)
E/flutter ( 5737): #9      _MapStream._handleData  (dart:async/stream_pipe.dart:232:10)
E/flutter ( 5737): #10     _ForwardingStreamSubscription._handleData  (dart:async/stream_pipe.dart:164:13)
E/flutter ( 5737): #11     _rootRunUnary  (dart:async/zone.dart:1132:38)
E/flutter ( 5737): #12     _CustomZone.runUnary  (dart:async/zone.dart:1029:19)
E/flutter ( 5737): #13     _CustomZone.runUnaryGuarded  (dart:async/zone.dart:931:7)
E/flutter ( 5737): #14     _BufferingStreamSubscription._sendData  (dart:async/stream_impl.dart:336:11)
E/flutter ( 5737): #15     _DelayedData.perform  (dart:async/stream_impl.dart:591:14)
E/flutter ( 5737): #16     _StreamImplEvents.handleNext  (dart:async/stream_impl.dart:707:11)
E/flutter ( 5737): #17     _PendingEvents.schedule.<anonymous closure>  (dart:async/stream_impl.dart:667:7)
E/flutter ( 5737): #18     _rootRun  (dart:async/zone.dart:1120:38)
E/flutter ( 5737): #19     _CustomZone.run  (dart:async/zone.dart:1021:19)
E/flutter ( 5737): #20     _CustomZone.runGuarded  (dart:async/zone.dart:923:7)
E/flutter ( 5737): #21     _CustomZone.bindCallbackGuarded.<anonymous closure>  (dart:async/zone.dart:963:23)
E/flutter ( 5737): #22     _rootRun  (dart:async/zone.dart:1124:13)
E/flutter ( 5737): #23     _CustomZone.run  (dart:async/zone.dart:1021:19)
E/flutter ( 5737): #24     _CustomZone.runGuarded  (dart:async/zone.dart:923:7)
E/flutter ( 5737): #25     _CustomZone.bindCallbackGuarded.<anonymous closure>  (dart:async/zone.dart:963:23)
E/flutter ( 5737): #26     _microtaskLoop  (dart:async/schedule_microtask.dart:41:21)
E/flutter ( 5737): #27     _startMicrotaskLoop  (dart:async/schedule_microtask.dart:50:5)
@isgj
Copy link
Author

isgj commented Jul 16, 2019

I noticed that on real devices when the app is build in debug mode it won't redirect, in release mode it works. Probably should close this issue.

@Clancey Clancey closed this as completed Jul 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants