Skip to content

Commit f44618a

Browse files
committed
bitbox02/bootloader: log monotonic version
Sometimes users get 'invalid firmware' and go into the bootloader screen without the button to install/upgrade `CanUpgrade=false`. This should never happen if the user is using the latest app release. This may help debug the problem should it appear again.
1 parent 6a7b89f commit f44618a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

backend/devices/bitbox02bootloader/device.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,11 @@ func (device *Device) VersionInfo() (*VersionInfo, error) {
164164
return nil, err
165165
}
166166
canUpgrade := erased || bundledFirmwareVersion > currentFirmwareVersion
167+
device.log.
168+
WithField("bundledFirmwareVersion", bundledFirmwareVersion).
169+
WithField("currentFirmwareVersion", currentFirmwareVersion).
170+
WithField("erased", erased).
171+
WithField("canUpgrade", canUpgrade).Info("VersionInfo")
167172
return &VersionInfo{
168173
Erased: erased,
169174
CanUpgrade: canUpgrade,

0 commit comments

Comments
 (0)