From c987711ec3ef207c4da59d7eac9b258012981604 Mon Sep 17 00:00:00 2001 From: Ilka Schulz <83639952+ilka-schulz@users.noreply.github.com> Date: Fri, 17 Nov 2023 08:23:30 +0100 Subject: [PATCH] make connection thread daemonic (otherwise, programs can have trouble terminating) (#24) Co-authored-by: Ilka Schulz --- thales_remote/connection.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/thales_remote/connection.py b/thales_remote/connection.py index 820faa6..afbdb10 100644 --- a/thales_remote/connection.py +++ b/thales_remote/connection.py @@ -304,7 +304,9 @@ def _startTelegramListener(self) -> None: starts the thread handling the asyncronously incoming data """ self._receiving_worker_is_running = True - self._receiving_worker = threading.Thread(target=self._telegramListenerJob) + self._receiving_worker = threading.Thread( + target=self._telegramListenerJob, daemon=True + ) self._receiving_worker.start() return