Periodic Invalid Grant
Closed this issue · 5 comments
Hello, I keep getting invalid grant every few days or weeks or so. I do not know exactly when it stops. However, it is periodic.
I delete my token file. And run authorize from scratch. It tends to work for a few days, and then stops. Is there a common issue that I am not aware of? Has anyone taken any steps to diagnose this?
Thank you kindly in advance.
Hi @alexio215 , this is a common issue, it typically arises when your app remains in "test" mode, leading to tokens expiring approximately every week or so. To resolve this, you need to publish your app on Google Cloud Platform:
- Navigate to your Google Cloud Project.
- Go to the "OAuth consent screen" tab.
-
- Locate the "Publishing Status" section.
-
- Here, you should see an option to "Publish App." Click this button.
-
- Review and confirm the necessary permissions as prompted.
- By publishing your app, you extend the token's lifespan, eliminating the need for frequent reauthorizations.
@randomBrainstormer Thank you very much. I just had a quick question regarding this. Does it become an issue of it becoming available to the public? Or does the data and module stay private? Thank you, and apologies if any of the questions come as naive.
Hi @alexio215, no worries at all – your questions are absolutely valid! You can rest assured that it's safe: your data remains private since you're the only one authenticating against your own app, and the OAuth credentials are used solely within your instance of the plugin, there's no public exposure to worry about ; ) If you have any more questions, feel free to ask! 😊
Changing the credentials to take it out of testing mode worked great for me. Thanks randomBrainstormer for explaining it so well.
Closing this issue for now, but if you require any further assistance, feel free to let me know, @alexio215