Telegram not working over Proxy
Expected Behavior
It should connect with the Telegram
Actual Behavior
I get this error when I execute the sh by setting the environment Proxy variable using:
/usr/bin/env HTTPS_PROXY="xxxx"
Output when issue occurred
[2016-08-29 01:31:44] [ cli] [INFO] Most Perfect Pokemon: Traceback (most recent call last): File "pokecli.py", line 768, in
main() File "pokecli.py", line 119, in main bot = start_bot(bot,config) File "pokecli.py", line 87, in start_bot initialize_task(bot,config) File "pokecli.py", line 78, in initialize_task tree = TreeConfigBuilder(bot, config.raw_tasks).build() File "/Users/Jose/PokemonGo-Bot/pokemongo_bot/tree_config_builder.py", line 79, in build instance = worker(self.bot, task_config) File "/Users/Jose/PokemonGo-Bot/pokemongo_bot/base_task.py", line 23, in init self.initialize() File "/Users/Jose/PokemonGo-Bot/pokemongo_bot/cell_workers/telegram_task.py", line 33, in initialize self.update_id = self.tbot.getUpdates()[0].update_id File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/telegram/bot.py", line 121, in decorator result = func(self, _args, *_kwargs) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/telegram/bot.py", line 1220, in getUpdates result = request.post(url, data, timeout=urlopen_timeout) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/telegram/utils/request.py", line 235, in post *_urlopen_kwargs) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/telegram/utils/request.py", line 160, in _request_wrapper resp = _get_con_pool().request(_args, *_kwargs) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/telegram/utils/request.py", line 46, in _get_con_pool _init_con_pool() File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/telegram/utils/request.py", line 64, in _init_con_pool mgr = urllib3.proxy_from_url(proxy_url, *_kwargs) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/urllib3/poolmanager.py", line 367, in proxy_from_url return ProxyManager(proxy_url=url, *_kw) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/urllib3/poolmanager.py", line 318, in init raise ProxySchemeUnknown(proxy.scheme) urllib3.exceptions.ProxySchemeUnknown: Not supported proxy scheme None [2016-08-29 01:31:44] [sentry.errors] [ERROR] Sentry responded with an error: 'utf8' codec can't decode byte 0x9c in position 1: invalid start byte (url: https://app.getsentry.com/api/90254/store/) Traceback (most recent call last): File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/raven/transport/threaded.py", line 174, in send_sync super(ThreadedHTTPTransport, self).send(data, headers) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/raven/transport/http.py", line 47, in send ca_certs=self.ca_certs, File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/raven/utils/http.py", line 66, in urlopen return opener.open(url, data, timeout) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/future/backports/urllib/request.py", line 494, in open response = self._open(req, data) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/future/backports/urllib/request.py", line 512, in _open '_open', req) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/future/backports/urllib/request.py", line 466, in _call_chain result = func(_args) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/raven/utils/http.py", line 46, in https_open return self.do_open(ValidHTTPSConnection, req) File "/Users/Jose/PokemonGo-Bot/lib/python2.7/site-packages/future/backports/urllib/request.py", line 1284, in do_open h.request(req.get_method(), req.selector, req.data, headers) File "/usr/local/Cellar/python/2.7.11/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py", line 1057, in request self._send_request(method, url, body, headers) File "/usr/local/Cellar/python/2.7.11/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py", line 1097, in _send_request self.endheaders(body) File "/usr/local/Cellar/python/2.7.11/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py", line 1053, in endheaders self._send_output(message_body) File "/usr/local/Cellar/python/2.7.11/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py", line 895, in _send_output msg += message_body File "/Users/Jose/PokemonGo-Bot/lib/python2.7/encodings/utf_8.py", line 16, in decode return codecs.utf_8_decode(input, errors, True) UnicodeDecodeError: 'utf8' codec can't decode byte 0x9c in position 1: invalid start byte [2016-08-29 01:31:44] [sentry.errors.uncaught] [ERROR] [u'ProxySchemeUnknown: Not supported proxy scheme None', u' File "pokecli.py", line 768, in ', u' File "pokecli.py", line 119, in main', u' File "pokecli.py", line 87, in start_bot', u' File "pokecli.py", line 78, in initialize_task', u' File "pokemongo_bot/tree_config_builder.py", line 79, in build', u' File "pokemongo_bot/base_task.py", line 23, in init', u' File "pokemongo_bot/cell_workers/telegram_task.py", line 33, in initialize', u' File "telegram/bot.py", line 121, in decorator', u' File "telegram/bot.py", line 1220, in getUpdates', u' File "telegram/utils/request.py", line 235, in post', u' File "telegram/utils/request.py", line 160, in _request_wrapper', u' File "telegram/utils/request.py", line 46, in _get_con_pool', u' File "telegram/utils/request.py", line 64, in _init_con_pool', u' File "urllib3/poolmanager.py", line 367, in proxy_from_url', u' File "urllib3/poolmanager.py", line 318, in init']
Other Information
OS: Mac OS X 10.10
Branch: Dev
Git Commit: 007f02a35726947b7378aada3fb0cf8d0b462b36
Python Version: Python 2.7.10
You wrong use proxy. Right: /usr/bin/env HTTPS_PROXY="http://xxxx" or /usr/bin/env HTTPS_PROXY="https://xxxx"
@askovpen I know that, and I'm using it like that.
whats problem?
It's fixed now.