chore(release): 0.5.0 #13

Merged
pufereq merged 33 commits from release/0.5.0 into main 2026-02-28 22:48:50 +00:00
2 changed files with 350 additions and 240 deletions
Showing only changes of commit 3077a98d6f - Show all commits

View File

@@ -73,6 +73,16 @@ class BackendServer:
self.logger.info(f"[>] Sending ACK to {client}") self.logger.info(f"[>] Sending ACK to {client}")
client.outbound += ack client.outbound += ack
def send_close(self, client: Client) -> None:
"""Send a CLOSE message to a client.
Args:
client (Client): The client to send the CLOSE message to.
"""
close_msg: bytes = Message.close().to_bytes()
self.logger.info(f"[>] Sending CLOSE to {client}")
client.outbound += close_msg
def _accept_connection(self, sock: socket.socket) -> None: def _accept_connection(self, sock: socket.socket) -> None:
"""Accept a new client connection. """Accept a new client connection.
@@ -96,7 +106,6 @@ class BackendServer:
sock (socket.socket): The client socket to disconnect. sock (socket.socket): The client socket to disconnect.
""" """
self.logger.info(f"[-] Disconnecting {client}...") self.logger.info(f"[-] Disconnecting {client}...")
self.logger.debug("[*] Sending DNR message...")
try: try:
self.selector.unregister(client.socket) self.selector.unregister(client.socket)