kiwiz/gkeepapi

403 exception apparently on googleapis url

jp5282 opened this issue · 5 comments

Please make sure you've done the following before submitting your issue:

  • Check that you're running the newest version of the library.
    Confirmed updated to 0.11.15
  • If you're providing a stack trace, make sure it doesn't contain your password.
    Exception on login. 403 on https://www.googleapis.com/reminders/v1internal/reminders/
    Let me know if we need a stack trace
  • If you're getting a KeyError or ParseException, please follow the instructions
    Not getting this. I have previously fixed such exceptions; that's not the case here.

I have also been getting a 403 exception. However, only on my account when using an app password. I get the stack trace:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/zack/.local/lib/python3.8/site-packages/gkeepapi/__init__.py", line 695, in login
    self.load(auth, state, sync)
  File "/home/zack/.local/lib/python3.8/site-packages/gkeepapi/__init__.py", line 741, in load
    self.sync(True)
  File "/home/zack/.local/lib/python3.8/site-packages/gkeepapi/__init__.py", line 996, in sync    changes = self._reminders_api.list()
  File "/home/zack/.local/lib/python3.8/site-packages/gkeepapi/__init__.py", line 592, in list
    return self.send(
  File "/home/zack/.local/lib/python3.8/site-packages/gkeepapi/__init__.py", line 229, in send
    raise exception.APIException(error['code'], error)
gkeepapi.exception.APIException: {'errors': [{'domain': 'global', 'reason': 'forbidden', 'message': 'Forbidden'}], 'code': 403, 'message': 'Forbidden'}

I should clarify also that I too am using app password given MFA access to my Google account.

Ditto using app password with same traceback. Just encountered this tonight. I upgraded to 0.11.15 and still have error.

`Python Scripts/keepExtractor.py', wdir='F:/u/mike/Documents/Python Scripts')
Traceback (most recent call last):

  File "F:\u\mike\Documents\Python Scripts\keepExtractor.py", line 11, in <module>
    keep.login('mac....', '....')

  File "C:\Users\mike\anaconda307a\lib\site-packages\gkeepapi\__init__.py", line 695, in login
    self.load(auth, state, sync)

  File "C:\Users\mike\anaconda307a\lib\site-packages\gkeepapi\__init__.py", line 741, in load
    self.sync(True)

  File "C:\Users\mike\anaconda307a\lib\site-packages\gkeepapi\__init__.py", line 996, in sync
    changes = self._reminders_api.list()

  File "C:\Users\mike\anaconda307a\lib\site-packages\gkeepapi\__init__.py", line 595, in list
    json=params

  File "C:\Users\mike\anaconda307a\lib\site-packages\gkeepapi\__init__.py", line 229, in send
    raise exception.APIException(error['code'], error)

APIException: {'errors': [{'domain': 'global', 'reason': 'forbidden', 'message': 'Forbidden'}], 'code': 403, 'message': 'Forbidden'}`
kiwiz commented

Something has changed with the Reminders API. I don't have time to debug this atm, so I'm going to disable it. 0.11.16 should fix the problem.

Thank you for your fast response. That change worked for me.