AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Informational 19 Bitcoin

build: fix trezor: new trezorlib 0.20 now requires *.dist-info metadata

Public commit record

What the developer wrote

Authored by SomberNight

93/100 · Strong
build: fix trezor: new trezorlib 0.20 now requires *.dist-info metadata

```
8.16 | W | gui.qt.wizard.wallet.WCChooseHWDevice | error getting device infos for trezor: Library version for 'trezor' is incompatible. // Installed: unknown, Needed: 0.20.0 <= x < 0.21 // Make sure you install it with python3
```

```
>>> trezorlib.__version__
Traceback (most recent call last):
File "<string>", line 1, in <module>
NameError: name 'trezorlib' is not defined
>>> import trezorlib
>>> trezorlib.__version__
Traceback (most recent call last):
File "/tmp/.mount_electrcmMljC/usr/lib/python3.12/importlib/metadata/__init__.py", line 397, in from_name
return next(cls.discover(name=name))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/.mount_electrcmMljC/usr/lib/python3.12/site-packages/trezorlib/__init__.py", line 27, in __getattr__
return importlib.metadata.version("trezor")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/.mount_electrcmMljC/usr/lib/python3.12/importlib/metadata/__init__.py", line 889, in version
return distribution(distribution_name).version
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/.mount_electrcmMljC/usr/lib/python3.12/importlib/metadata/__init__.py", line 862, in distribution
return Distribution.from_name(distribution_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/.mount_electrcmMljC/usr/lib/python3.12/importlib/metadata/__init__.py", line 399, in from_name
raise PackageNotFoundError(name)
importlib.metadata.PackageNotFoundError: No package metadata was found for trezor

```

We generally don't bundle the *.dist-info importlib metadata stuff as for many packages, these files are not reproducible.

ref
https://github.com/spesmilo/electrum/commit/aecc22dc081339fb570a7a3b09f3e47bf9ea5021
https://github.com/spesmilo/electrum/commit/c52a29fc221f8fdbe55872084f215478c957010d

(cherry picked from commit f8226f9384369ca30a2c4811cd631eb77719f97e)
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Uses a recognizable type or scope✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
The short version

What changed, and why it matters

This commit fixes a build/packaging problem in Electrum's bundled desktop releases (AppImage, Windows, macOS). A newer version of the Trezor hardware-wallet library now needs its package metadata files to be present, otherwise it cannot report its version and Electum wrongly treats it as incompatible. The change simply includes those metadata files in the bundled app. It is a reliability fix, not a security vulnerability patch.

Recommended action

No security action required; treat as a normal build fix. Users relying on Trezor hardware wallets in bundled Electrum releases should upgrade to a build containing this commit to restore Trezor functionality.

Security signals we found

01

No security-relevant code change

02

Build/packaging compatibility fix only

03

No attacker-controlled input is processed

04

No memory safety, cryptography, or authorization changes

Risk score

Why this scored 19/100

Our methodology →
Potential impact 2/30
Exploitability 0/25
Stealth signal 0/15
Affected reach 5/15
Confidence 8/10
Evidence quality 4/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.