Skip to content

browser auth cause Failed assertion: line 11 pos 12: '_window != null' is not true. #59

@tomaszkubacki

Description

@tomaszkubacki

Following code:

GoogleOAuth2 auth = new GoogleOAuth2(CLIENT_ID, [SCOPE]);
auth.login().then((t){

...
});

causes below in polymer app. Dartium 1.5.7

Uncaught Error: 'package:google_oauth2_client/src/browser/utils.dart': Failed assertion: line 11 pos 12: '_window != null' is not true.
Stack Trace:
#0 _WindowPoller._WindowPoller (package:google_oauth2_client/src/browser/utils.dart:11:12)
#1 GoogleOAuth2.login.completeByPromptingUser. (package:google_oauth2_client/src/browser/google_oauth2.dart:171:21)
#2 _rootRunUnary (dart:async/zone.dart:730)
#3 _RootZone.runUnary (dart:async/zone.dart:864)
#4 _Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:488)
#5 _Future._propagateToListeners (dart:async/future_impl.dart:571)
#6 _Future._completeWithValue (dart:async/future_impl.dart:331)
#7 _Future._asyncComplete. (dart:async/future_impl.dart:393)
#8 _asyncRunCallbackLoop (dart:async/schedule_microtask.dart:23)
#9 _asyncRunCallback (dart:async/schedule_microtask.dart:32)
#10 _handleMutation (dart:html:38346)

Exception: 'package:google_oauth2_client/src/browser/utils.dart': Failed assertion: line 11 pos 12: '_window != null' is not true.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions