Usually the first time I run a script on my Ubuntu laptop I get:
"(...)"
raise NotConnectedError("Characteristic discovery failed")
pygatt.exceptions.NotConnectedError: Characteristic discovery failed
If I run it again it works fine. Usually several times.
Problem seems to occur just the first time the HCI device is used.