From df27ebc27effbe99bfac5cce9324478e3d5f11ef Mon Sep 17 00:00:00 2001 From: David Lechner Date: Tue, 16 Mar 2021 19:40:22 -0500 Subject: [PATCH] pybricks.messaging: fix BluetoothMailboxServer close As per standard Python socketserver, there is `server_close()` rather than `close()`. Fixes #51 --- pybricks/messaging.py | 2 +- pybricks/messaging.pyi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pybricks/messaging.py b/pybricks/messaging.py index 6f4b98c..2e7a3e2 100644 --- a/pybricks/messaging.py +++ b/pybricks/messaging.py @@ -180,5 +180,5 @@ class BluetoothMailboxClient: There was a problem establishing the connection. """ - def close(self): + def server_close(self): """Closes all connections.""" diff --git a/pybricks/messaging.pyi b/pybricks/messaging.pyi index 5b8712a..9c9c4cb 100644 --- a/pybricks/messaging.pyi +++ b/pybricks/messaging.pyi @@ -40,7 +40,7 @@ class BluetoothMailboxServer(Connection): def __enter__(self) -> BluetoothMailboxServer: ... def __exit__(self, type, value, traceback) -> None: ... def wait_for_connection(self, count: int = 1) -> None: ... - def close(self) -> None: ... + def server_close(self) -> None: ... class BluetoothMailboxClient(Connection): def __enter__(self) -> BluetoothMailboxClient: ...