• 1399/11/08

ارور کانکشن :

سلام و عرض خسته نباشید خدمت استاد متین.....

بنده وقتی کد را اجرا میکنم(حتی پروژه ای که خودتون در ویدیوی ششم گذاشتین را هم تست کردم)به ارور زیر بر میخورم مشکلش چیه؟

Traceback (most recent call last):
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connection.py", line 169, in _new_conn
    conn = connection.create_connection(
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\util\connection.py", line 96, in create_connection
    raise err
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\util\connection.py", line 86, in create_connection
    sock.connect(sa)
TimeoutError: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond     

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 699, in urlopen
    httplib_response = self._make_request(
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 382, in _make_request
    self._validate_conn(conn)
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 1010, in _validate_conn
    conn.connect()
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connection.py", line 353, in connect
    conn = self._new_conn()
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connection.py", line 181, in _new_conn
    raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x0000012E9CFB26A0>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\requests\adapters.py", line 439, in send
    resp = conn.urlopen(
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 755, in urlopen
    retries = retries.increment(
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\util\retry.py", line 573, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='api.telegram.org', port=443): Max retries exceeded with url: /bot1600143316:AAGViahSkdvM06UqON-LHVN868rUZP-aL8s%E2%80%8F/getUpdates?offset=1&amp;timeout=20 (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x0000012E9CFB26A0>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "c:/Users/parsian/Desktop/python.project/bot.py", line 30, in <module>
    bot.polling(True)
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\telebot\__init__.py", line 
485, in polling
    self.__threaded_polling(none_stop, interval, timeout, long_polling_timeout)
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\telebot\__init__.py", line 
544, in __threaded_polling
    raise e
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\telebot\__init__.py", line 
506, in __threaded_polling
    polling_thread.raise_exceptions()
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\telebot\util.py", line 87, 
in raise_exceptions
    raise self.exception_info
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\telebot\util.py", line 69, 
in run
    task(*args, **kwargs)
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\telebot\__init__.py", line 
322, in __retrieve_updates
    updates = self.get_updates(offset=(self.last_update_id + 1), timeout=timeout, long_polling_timeout = long_polling_timeout)
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\telebot\__init__.py", line 
292, in get_updates
    json_updates = apihelper.get_updates(self.token, offset, limit, timeout, allowed_updates, long_polling_timeout)
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\telebot\apihelper.py", line 281, in get_updates
    return _make_request(token, method_url, params=payload)
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\telebot\apihelper.py", line 126, in _make_request
    result = _get_req_session().request(
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\requests\sessions.py", line 542, in request
    resp = self.send(prep, **send_kwargs)
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\requests\sessions.py", line 655, in send
    r = adapter.send(request, **kwargs)
  File "C:\Users\parsian\AppData\Local\Programs\Python\Python38\lib\site-packages\requests\adapters.py", line 516, in send
    raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='api.telegram.org', port=443): Max retries exceeded with url: /bot1600143316:AAGViahSkdvM06UqON-LHVN868rUZP-aL8s%E2%80%8F/getUpdates?offset=1&amp;timeout=20 (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x0000012E9CFB26A0>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond'))
  • 1399/11/19
  • ساعت 13:24

فکر کنم به خاطر فیلتر شدن تلگرامه

 


logo-enamadlogo-samandehi