Answer the question
In order to leave comments, you need to log in
How to set up config vars in heroku?
in the heroku tutorials it is written that the configuration variables of the bot token type must be filled with the heroku config:set TOKEN=... command, which I did, and use them using the boto library, which I also repeated, but after starting the bot immediately stops and writes the following
2017-05-31T16:08:36.912981+00:00 app[worker.1]: 'Check your credentials' % (len(names), str(names)))
2017-05-31T16:08:36.912997+00:00 app[worker.1]: boto.exception.NoAuthHandlerFound: No handler was ready to authenticate. 1 handlers were checked. ['HmacAuthV1Handler'] Check your credentials
2017-05-31T16:08:37.019342+00:00 heroku[worker.1]: State changed from up to crashed
2017-05-31T16:26:44.164914+00:00 heroku[worker.1]: State changed from crashed to starting
2017-05-31T16:26:47.958429+00:00 heroku[worker.1]: Starting process with command `python bot.py`
2017-05-31T16:26:48.592575+00:00 heroku[worker.1]: State changed from starting to up
2017-05-31T16:26:51.186450+00:00 heroku[worker.1]: Process exited with status 1
2017-05-31T16:26:51.095908+00:00 app[worker.1]: Traceback (most recent call last):
2017-05-31T16:26:51.095927+00:00 app[worker.1]: File "bot.py", line 6, in <module>
2017-05-31T16:26:51.095929+00:00 app[worker.1]: bot = telebot.TeleBot(str(S3Connection(os.environ['TOKEN'])))
2017-05-31T16:26:51.095930+00:00 app[worker.1]: File "/app/.heroku/python/lib/python3.6/site-packages/boto/s3/connection.py", line 191, in __init__
2017-05-31T16:26:51.095931+00:00 app[worker.1]: File "/app/.heroku/python/lib/python3.6/site-packages/boto/connection.py", line 569, in __init__
2017-05-31T16:26:51.095930+00:00 app[worker.1]: validate_certs=validate_certs, profile_name=profile_name)
2017-05-31T16:26:51.095932+00:00 app[worker.1]: host, config, self.provider, self._required_auth_capability())
2017-05-31T16:26:51.095932+00:00 app[worker.1]: File "/app/.heroku/python/lib/python3.6/site-packages/boto/auth.py", line 1021, in get_auth_handler
from boto.s3.connection import S3Connection
token = S3Connection(os.environ['TOKEN'])
bot = telebot.TeleBot(token)
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question