def __init__(self, host='127.0.0.1', port=23, application=None, encoding='utf-8'):
    assert isinstance(host, text_type)
    assert isinstance(port, int)
    assert isinstance(application, TelnetApplication)
    assert isinstance(encoding, text_type)
    self.host = host
    self.port = port
    self.application = application
    self.encoding = encoding
    self.connections = set()
    self._calls_from_executor = []
    self._schedule_pipe = os.pipe()
    fcntl.fcntl(self._schedule_pipe[0], fcntl.F_SETFL, os.O_NONBLOCK)
def __init__(self, host='127.0.0.1', port=23, application=None, encoding='utf-8'):
    assert isinstance(host, text_type)
    assert isinstance(port, int)
    assert isinstance(application, TelnetApplication)
    assert isinstance(encoding, text_type)
    self.host = host
    self.port = port
    self.application = application
    self.encoding = encoding
    self.connections = set()
    self._calls_from_executor = []
    self._schedule_pipe = os.pipe()
    fcntl.fcntl(self._schedule_pipe[0], fcntl.F_SETFL, os.O_NONBLOCK)