Skip to content

timeout when start_polling with clean=True #275

@shouya

Description

@shouya

code to reproduce the problem:

updater = Updater(token=xxx)
updater.start_polling(clean=True)

error output:

Traceback (most recent call last):
  File "main.py", line 43, in <module>
    main()
  File "main.py", line 34, in main
    updates = bot.getUpdates()
  File "/usr/local/lib/python3.5/site-packages/telegram/bot.py", line 114, in decorator
    result = func(self, *args, **kwargs)
  File "/usr/local/lib/python3.5/site-packages/telegram/bot.py", line 1315, in getUpdates
    result = request.post(url, data, timeout=urlopen_timeout)
  File "/usr/local/lib/python3.5/site-packages/telegram/utils/request.py", line 83, in decorator
    raise NetworkError('URLError: {0}'.format(error.reason))
telegram.error.NetworkError: URLError: _ssl.c:629: The handshake operation timed out
$ pip3 list | grep telegram
python-telegram-bot (4.0.3)

I'll fire a PR to fix this later.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions