

def _send_close(self):
    args = Writer()
    args.write_short(self.connection._close_info['reply_code'])
    args.write_shortstr(self.connection._close_info['reply_text'][:255])
    args.write_short(self.connection._close_info['class_id'])
    args.write_short(self.connection._close_info['method_id'])
    self.send_frame(MethodFrame(self.channel_id, 10, 50, args))
    self.add_synchronous_cb(self._recv_close_ok)

dataset/ETHPy150Open agoragames/haigha/haigha/connection.py ConnectionChannel._send_close/original