btoews / OctoGAS

GitHub Email Notifications Google Apps Script for Gmail
100 stars 22 forks source link

Infinite loop: Keeps asking for permissions #20

Open watson opened 8 years ago

watson commented 8 years ago

Every time I give the website permissions to access my inbox, I'm redirected back to the same page with the same message letting me know that it wants permissions to access my inbox.

Could this be because I have more than one Gmail account and it then tries to access the wrong one not knowing that I already gave it access to another account?

muan commented 8 years ago

Could this be because I have more than one Gmail account and it then tries to access the wrong one not knowing that I already gave it access to another account?

😢 Have you tried appending the install URL with &authuser=1 (or whichever the index of your logged in accounts)? or is this happening regardless?

btoews commented 8 years ago

I wonder if the OAuth flow is failing. Is there anything in the query part of the URL in your address bar, like ?error=...?

watson commented 7 years ago

@muan Which is the install URL? @mastahyeti I don't see ?error=... in the URL after being redirected back to the auth page

I first see this page:

screen shot 2016-09-25 at 18 15 20

First time I clicked "Review permissions", I was taken to a pop-up page asking for permissions to access my primary Google account. There were an account switcher in the top right corner that I used to switch to the Google account I wanted to use and it asked me for these permissions:

screen shot 2016-09-25 at 18 15 41

I was now taken back to the page shown in the first screenshot above. When clicking the "Review permissions" again I was shown the pop-up asking for permissions for my primary (but wrong) Google account. When switching to the account I wanted, I now saw it asking for this permission instead:

screen shot 2016-09-25 at 18 15 49

After accepting that permission I'm taken back to the first page again. And every time I click "Review permissions", I'm going through this flow again.