Problems with PTB
ruizlenato opened this issue · 5 comments
ruizlenato commented
2021-04-16 00:35:27,771 - telegram.ext.dispatcher - ERROR - No error handlers are registered, logging exception.
Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/python_telegram_bot-13.4.1-py3.8.egg/telegram/ext/utils/promise.py", line 79, in run
self._result = self.pooled_function(*self.args, **self.kwargs)
File "/home/ubuntu/SmudgePTB13/smudge/modules/stickers.py", line 111, in kang kang_file.download('kangsticker.png')
File "/usr/local/lib/python3.8/dist-packages/python_telegram_bot-13.4.1-py3.8.egg/telegram/files/file.py", line 159, in download
buf = self.bot.request.retrieve(url, timeout=timeout)
File "/usr/local/lib/python3.8/dist-packages/python_telegram_bot-13.4.1-py3.8.egg/telegram/utils/request.py", line 373, in retrieve
return self._request_wrapper('GET', url, **urlopen_kwargs)
File "/usr/local/lib/python3.8/dist-packages/python_telegram_bot-13.4.1-py3.8.egg/telegram/utils/request.py", line 274, in _request_wrapper
raise InvalidToken()
telegram.error.InvalidToken: Invalid token
I'm having trouble trying to upload an image
PTB 13.4, Python3.8.5
cavallium commented
You are using an invalid token
ruizlenato commented
You are using an invalid token
no, I know I'm not using an invalid Token, this problem only occurs when I try to download files from Telegram
giuseppeM99 commented
the botapi does not serve files, you have to setup a reverse proxy and serve the files statically
ruizlenato commented
the botapi does not serve files, you have to setup a reverse proxy and serve the files statically
Interesting, do you have any documentation or guides that I can follow / learn?
giuseppeM99 commented
@MarcoBuster made an example with docker, traefik and nginx, you can see the nginx config here https://github.com/MarcoBuster/tdlight-telegram-bot-api-traefik/blob/master/botapi/static_nginx.conf