-
Notifications
You must be signed in to change notification settings - Fork 104
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add a warning in debug mode upon "Call to 'getMe' failed! (401: Unauthorized)" that the bot token is incorrect #561
Comments
Closing per https://t.me/grammyjs/229944. |
In my case the token was invalid because I accidentally appended a letter. It would have been ideal to get a "Token might be invalid" suggestion in the error, but I should have also figured it out from the 401. |
This is already documented at https://grammy.dev/resources/faq#_401-unauthorized |
@KnorpelSenf agreed, and I missed that - but what I meant now is in code. If it's clear that 401 means error is on the side of the user and token is invalid, then it would be safe and very helpful to put that in the error message (to make it more informative). |
That's a really good idea actually |
Nice, I'm glad you like it! |
Please review #574 and approve it if these changes work for you |
Thank you for adding and merging this, and listing me in contributors! 💟 That's so nice. I'm sorry I didn't answer sooner, I don't check my GitHub notifications often enough |
You're welcome :) No worries! You can enable email notifications so you don't have to check manually |
hi!
I'm trying to deploy my bot and starting with following examples in the docs. I get to the same error in 2-3 ways:
Here's a copy-paste of the error from my local attempt with Docker:
The text was updated successfully, but these errors were encountered: