Chrome App authentication fails with chrome.runtime.identity.getAuthToken: authorization page cannot be loaded

I authenticate my user when he clicks the sign in button in my Chrome application. This opens up a new page in Chrome, inviting them to sign in to their Google account. Then a popup window opens asking for the permissions that my application is requesting. When they click ok, the application gets token - everything works fine until I switch to another locale.

When I test the application in Korean, token undefined after a successful login. I researched further, and I found out that I am getting the error chrome.runtime.identity.getAuthToken: Authorization page could not be loaded .

 extensions::lastError:133 Unchecked runtime.lastError while running identity.getAuthToken: Authorization page could not be loaded. at chrome-extension://APP_ID/foreground/bundle/app.js:29630:24 at chrome-extension://APP_ID/foreground/bundle/app.js:28068:46 at Object.loadUserPlaylists (chrome-extension://APP_ID/foreground/bundle/app.js:27679:13) at SidebarPlaylists.onSignInAndLoadUserPlaylists (chrome-extension://APP_ID/foreground/bundle/app.js:42014:19) at Object.invokeGuardedCallback (chrome-extension://APP_ID/foreground/bundle/app.js:11872:13) at executeDispatch (chrome-extension://APP_ID/foreground/bundle/app.js:11717:22) at Object.executeDispatchesInOrder (chrome-extension://APP_ID/foreground/bundle/app.js:11737:8) 

This prevents the login and use of my Chrome app in Korea. Why is this happening and how can I fix it?

Update:

Adding the following permissions did not help:

 "https://*.chromiumapp.org/*", "https://chromiumapp.org/", "https://*.apps.googleusercontent.com/", "https://apps.googleusercontent.com/", "https://apps.googleusercontent.com/", "https://apps.googleusercontent.com/", "https://*.chromiumapp.org/*/*" 

Update2:

I tried using launchWebAuthFlow() instead of identity.getAuthToken() .

  chrome.identity.launchWebAuthFlow({ url: "https://accounts.google.com/o/oauth2/v2/auth?scope=email&response_type=token&client_id=MY_CLIENT_ID&redirect_uri="+chrome.identity.getRedirectURL()+"&prompt=consent", interactive: true }, function(respUrl) { //respUrl is empty debugger; //getUserPlaylists(token, dispatch); 

It also gives me

extensions::lastError:133 Unchecked runtime.lastError while running identity.launchWebAuthFlow: Authorization page could not be loaded.

Mistake.

+7
google-chrome google-chrome-app
source share

No one has answered this question yet.

See related questions:

419
How do I search for all downloaded scripts in Chrome Developer Tools?
367
How to clear chrome authentication master data
266
Unusual error in Chrome Developer Console - Failed to load resource: net :: ERR_CACHE_MISS
151
Failed to load asset in Chrome
5
Chrome oAuth extension Request page redirection without loading
2
Chrome script extension input extension get error
one
Chrome extension cannot be enabled until reinstall
0
How my Chrome profile may cause a Chrome extension error: "The manifest extension must request permission to access this host."
0
Download a blank web page using Chrome without using "about: blank"

All Articles