Created
December 12, 2017 06:17
-
-
Save jeremydw/42139a15f2fc802d3bddeab95b64b646 to your computer and use it in GitHub Desktop.
Enforce account chooser on Google App Engine
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
When using the Google App Engine Users API, there is no way to enforce the account chooser for users signed in to multiple accounts. You can do so by using `users.create_login_url` and replacing the output of the function as so: | |
``` | |
from google.appengine.api import users | |
url = users.create_login_url() | |
url = url.replace('/accounts/ServiceLogin', '/a/SelectSession', 1) | |
``` | |
This is not guaranteed to work if the output of `users.create_login_url` changes. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment