diff --git a/python/.changelog.d/2904.fixed b/python/.changelog.d/2904.fixed new file mode 100644 index 000000000..67b7f4be5 --- /dev/null +++ b/python/.changelog.d/2904.fixed @@ -0,0 +1 @@ +Removed attempt to initialize the device after wipe in bootloader mode diff --git a/python/src/trezorlib/device.py b/python/src/trezorlib/device.py index 79c75eff8..bad8d5b75 100644 --- a/python/src/trezorlib/device.py +++ b/python/src/trezorlib/device.py @@ -101,7 +101,8 @@ def sd_protect( @session def wipe(client: "TrezorClient") -> "MessageType": ret = client.call(messages.WipeDevice()) - client.init_device() + if not client.features.bootloader_mode: + client.init_device() return ret