2.
3.
Tell us what should happen
$ virtualenv telegram-bot
$ source telegram-bot/bin/activate
$ pip install python-telegram-bot
Tell us what happens instead
error comes up
Operating System:
ubuntu 14.04
Version of Python, python-telegram-bot & dependencies:
python 2.7, latest python-telegram-bot
$ python -m telegram
Insert logs here (if necessary)
root@persian-telegram-bot:~# screen -S myTelegramBot
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/poolmanager.py", line 303, in urlopen
conn = self.connection_from_host(u.host, port=u.port, scheme=u.scheme)
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/poolmanager.py", line 219, in connection_from_host
return self.connection_from_context(request_context)
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/poolmanager.py", line 232, in connection_from_context
return self.connection_from_pool_key(pool_key, request_context=request_context)
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/poolmanager.py", line 245, in connection_from_pool_key
pool = self.pools.get(pool_key)
File "/root/telegram-bot/lib/python2.7/_abcoll.py", line 363, in get
return self[key]
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/_collections.py", line 53, in __getitem__
item = self._container.pop(key)
File "/usr/lib/python2.7/collections.py", line 138, in pop
if key in self:
TypeError: unhashable type: 'list'
Exception in thread updater:
Traceback (most recent call last):
File "/usr/lib/python2.7/threading.py", line 810, in __bootstrap_inner
self.run()
File "/usr/lib/python2.7/threading.py", line 763, in run
self.__target(*self.__args, **self.__kwargs)
File "/root/telegram-bot/local/lib/python2.7/site-packages/telegram/ext/updater.py", line 115, in _thread_wrapper
target(*args, **kwargs)
File "/root/telegram-bot/local/lib/python2.7/site-packages/telegram/ext/updater.py", line 228, in _start_polling
self._bootstrap(bootstrap_retries, clean=clean, webhook_url='')
File "/root/telegram-bot/local/lib/python2.7/site-packages/telegram/ext/updater.py", line 335, in _bootstrap
self.bot.setWebhook(webhook_url=webhook_url, certificate=cert)
File "/root/telegram-bot/local/lib/python2.7/site-packages/telegram/bot.py", line 125, in decorator
result = func(self, *args, **kwargs)
File "/root/telegram-bot/local/lib/python2.7/site-packages/telegram/bot.py", line 1280, in setWebhook
result = self._request.post(url, data, timeout=timeout)
File "/root/telegram-bot/local/lib/python2.7/site-packages/telegram/utils/request.py", line 207, in post
**urlopen_kwargs)
File "/root/telegram-bot/local/lib/python2.7/site-packages/telegram/utils/request.py", line 132, in _request_wrapper
resp = self._con_pool.request(*args, **kwargs)
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/request.py", line 70, in request
**urlopen_kw)
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/request.py", line 148, in request_encode_body
return self.urlopen(method, url, **extra_kw)
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/poolmanager.py", line 303, in urlopen
conn = self.connection_from_host(u.host, port=u.port, scheme=u.scheme)
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/poolmanager.py", line 219, in connection_from_host
return self.connection_from_context(request_context)
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/poolmanager.py", line 232, in connection_from_context
return self.connection_from_pool_key(pool_key, request_context=request_context)
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/poolmanager.py", line 245, in connection_from_pool_key
pool = self.pools.get(pool_key)
File "/root/telegram-bot/lib/python2.7/_abcoll.py", line 363, in get
return self[key]
File "/root/telegram-bot/local/lib/python2.7/site-packages/urllib3/_collections.py", line 53, in __getitem__
item = self._container.pop(key)
File "/usr/lib/python2.7/collections.py", line 138, in pop
if key in self:
TypeError: unhashable type: 'list'
Thank you for the commit. Now when i try to pip install lxml I get this error
Command /root/telegram-bot/bin/python -c "import setuptools, tokenize;__file__='/root/telegram-bot/build/lxml/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-zywS9a-record/install-record.txt --single-version-externally-managed --compile --install-headers /root/telegram-bot/include/site/python2.7 failed with error code 1 in /root/telegram-bot/build/lxml
Storing debug log for failure in /root/.pip/pip.log
Thank you for your report! I released a hotfix version to pypi. Please use pip install -U python-telegram-bot to upgrade.
I don't know about lxml, perhaps you don't have to required headers installed. This is not the right place for that question though.
Most helpful comment
Thank you for your report! I released a hotfix version to pypi. Please use
pip install -U python-telegram-botto upgrade.