From 8802c95d31873020fff94138bef0f53004bcff05 Mon Sep 17 00:00:00 2001 From: Vitalii Vydria Date: Mon, 14 Jul 2025 13:29:46 +0300 Subject: [PATCH] fix: metadata call for `peer_identity_address_type` Fixed a crash caused by a missing `metadata` initialization for the `peer_identity_address_type` field in the `HCI_LE_Set_Privacy_Mode_Command` dataclass. The absence of this call led to incorrect field setup, resulting in runtime exceptions during `HCI_LE_Set_Privacy_Mode_Command` handling. --- bumble/hci.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/bumble/hci.py b/bumble/hci.py index de2d6c3d..b9fe1c84 100644 --- a/bumble/hci.py +++ b/bumble/hci.py @@ -4990,7 +4990,9 @@ class HCI_LE_Set_Privacy_Mode_Command(HCI_Command): NETWORK_PRIVACY_MODE = 0x00 DEVICE_PRIVACY_MODE = 0x01 - peer_identity_address_type: int = field(metadata=Address.ADDRESS_TYPE_SPEC) + peer_identity_address_type: int = field( + metadata=metadata(Address.ADDRESS_TYPE_SPEC) + ) peer_identity_address: Address = field( metadata=metadata(Address.parse_address_preceded_by_type) )