From 3b479764dc013b5da3c1557fa29de967e4d0dfd2 Mon Sep 17 00:00:00 2001 From: Yoan Dumas Date: Sat, 7 Jan 2023 19:03:44 +0100 Subject: [PATCH] btle: close the PIPEd stdin and stdout from _helper This commit is fixing issue #498 about the annoying log regarding the RessourceWarning. Signed-off-by: Yoan Dumas --- bluepy/btle.py | 1 + 1 file changed, 1 insertion(+) diff --git a/bluepy/btle.py b/bluepy/btle.py index 3fa3564..d7ac117 100755 --- a/bluepy/btle.py +++ b/bluepy/btle.py @@ -304,6 +304,7 @@ def _stopHelper(self): DBG("Stopping ", helperExe) self._helper.stdin.write("quit\n") self._helper.stdin.flush() + self._helper.communicate() self._helper.wait() self._helper = None if self._stderr is not None: