| Server IP : 54.37.205.81 / Your IP : 216.73.216.76 Web Server : nginx/1.22.1 System : Linux vps-249481fa 6.1.0-50-cloud-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.176-1 (2026-07-02) x86_64 User : debian ( 1000) PHP Version : 8.2.32 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /usr/lib/python3/dist-packages/tornado/platform/__pycache__/ |
Upload File : |
�
��b�
� � � d dl Z d dlZd dlmZ d dlmZ d dlmZ d dlm Z m
Z
d dlZej rd dlm
Z
mZmZmZmZ G d� de � � ZdS ) � N)�Future)�gen)�IOLoop)�Resolver�is_valid_ip)� Generator�Any�List�Tuple�Dictc
�| � e Zd ZdZdd�Zdedededdfd�Zded eddfd
�Ze j
dded
ededdfd�� � ZdS )�
CaresResolvera� Name resolver based on the c-ares library.
This is a non-blocking and non-threaded resolver. It may not produce
the same results as the system resolver, but can be used for non-blocking
resolution when threads cannot be used.
c-ares fails to resolve some names when ``family`` is ``AF_UNSPEC``,
so it is only recommended for use in ``AF_INET`` (i.e. IPv4). This is
the default for ``tornado.simple_httpclient``, but other libraries
may default to ``AF_UNSPEC``.
.. versionchanged:: 5.0
The ``io_loop`` argument (deprecated since version 4.1) has been removed.
.. deprecated:: 6.2
This class is deprecated and will be removed in Tornado 7.0. Use the default
thread-based resolver instead.
�returnNc � � t j � � | _ t j | j �� � | _ i | _ d S )N)�
sock_state_cb)r �current�io_loop�pycares�Channel�_sock_state_cb�channel�fds)�selfs �@/usr/lib/python3/dist-packages/tornado/platform/caresresolver.py�
initializezCaresResolver.initialize# s3 � ��~�'�'�����T�5H�I�I�I�������� �fd�readable�writablec �J � |rt j nd|rt j ndz }|s$| j � |� � | j |= d S || j v r'| j � ||� � || j |<