```
$ ./run_electrum --testnet signmessage -w /home/user/.electrum/testnet/wallets/test_trezor_white_bip84 tb1q5pguna9y2g9y2gsu8r8gmxeye2cefvyly8dg02 heyheyhey -o
0.84 | W | plugins.jade.jadepy.jade | No module named 'electrum.plugins.jade.jadepy.jade_ble'
0.84 | W | plugins.jade.jadepy.jade | BLE scanning/connectivity will not be available
3.73 | E | __main__ | error running command (without daemon)
Traceback (most recent call last):
File "/home/user/wspace/electrum/electrum/plugins/trezor/clientbase.py", line 151, in get_xpub
node = trezorlib.btc.get_public_node(self.client, address_n).node
File "/home/user/.local/lib/python3.10/site-packages/trezorlib/tools.py", line 274, in wrapped_f
ret = f(*args, **kwargs)
File "/home/user/.local/lib/python3.10/site-packages/trezorlib/btc.py", line 125, in get_public_node
return client.call(
File "/home/user/.local/lib/python3.10/site-packages/trezorlib/tools.py", line 297, in wrapped_f
return f(client, *args, **kwargs)
File "/home/user/.local/lib/python3.10/site-packages/trezorlib/client.py", line 260, in call
resp = self._callback_pin(resp)
File "/home/user/.local/lib/python3.10/site-packages/trezorlib/client.py", line 186, in _callback_pin
pin = self.ui.get_pin(msg.type)
File "/home/user/wspace/electrum/electrum/plugins/trezor/clientbase.py", line 308, in get_pin
pin = self.handler.get_pin(msg.format(self.device), show_strength=show_strength)
AttributeError: 'NoneType' object has no attribute 'get_pin'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/user/wspace/electrum/./run_electrum", line 540, in handle_cmd
result = fut.result()
File "/usr/lib/python3.10/concurrent/futures/_base.py", line 458, in result
return self.__get_result()
File "/usr/lib/python3.10/concurrent/futures/_base.py", line 403, in __get_result
raise self._exception
File "/home/user/wspace/electrum/./run_electrum", line 227, in run_offline_command
password = get_password_for_hw_device_encrypted_storage(plugins)
File "/home/user/wspace/electrum/./run_electrum", line 212, in get_password_for_hw_device_encrypted_storage
return client.get_password_for_storage_encryption()
File "/home/user/wspace/electrum/electrum/plugin.py", line 523, in wrapper
return run_in_hwd_thread(partial(func, *args, **kwargs))
File "/home/user/wspace/electrum/electrum/plugin.py", line 516, in run_in_hwd_thread
return fut.result()
File "/usr/lib/python3.10/concurrent/futures/_base.py", line 458, in result
return self.__get_result()
File "/usr/lib/python3.10/concurrent/futures/_base.py", line 403, in __get_result
raise self._exception
File "/usr/lib/python3.10/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
File "/home/user/wspace/electrum/electrum/plugins/hw_wallet/plugin.py", line 260, in get_password_for_storage_encryption
xpub = self.get_xpub(derivation, "standard")
File "/home/user/wspace/electrum/electrum/plugin.py", line 523, in wrapper
return run_in_hwd_thread(partial(func, *args, **kwargs))
File "/home/user/wspace/electrum/electrum/plugin.py", line 513, in run_in_hwd_thread
return func()
File "/home/user/wspace/electrum/electrum/plugins/trezor/clientbase.py", line 150, in get_xpub
with self.run_flow(creating_wallet=creating):
File "/home/user/wspace/electrum/electrum/plugins/trezor/clientbase.py", line 89, in __exit__
self.end_flow()
File "/home/user/wspace/electrum/electrum/plugins/trezor/clientbase.py", line 82, in end_flow
self.handler.finished()
AttributeError: 'NoneType' object has no attribute 'finished'
```
- include a copy of pinmatrix.py from python-trezor, as-is
- adapt that to qt6: the upstream version(s) only support qt4/qt5
- use it in trezor/keepkey/safet plugins
3f1d2059ca/python/src/trezorlib/qt/pinmatrix.py
I will use this in the trezor (and clones) plugins in a modified form to work with qt6.
Otherwise we would have to ask the trezor devs, who would actually respond,
but also the keepkey and safet lib authors, who would not... to support qt6.
Haven't checked if electrum-ecc compiles libsecp reproducibly.
For now let's just keep the old flow.
(but if we spent time on making that compilation reproducible,
the appimage and the macos builds could use it directly)
There is an issue with plyer on Windows, which I thought was related to the mixed
backwards/forward slashes in the path, but no, this change still did not fix it:
```
1.84 | D | gui.qml.qeapp.QEAppController | sending push notification to OS: message='heyheyhey'
Traceback (most recent call last):
File "...\electrum\electrum\util.py", line 1111, in run_with_except_hook
run_original(*args2, **kwargs2)
File "...\Python310\lib\threading.py", line 953, in run
self._target(*self._args, **self._kwargs)
File "...\plyer\platforms\win\libs\balloontip.py", line 206, in balloon_tip
WindowsBalloonTip(**kwargs)
File "...\plyer\platforms\win\libs\balloontip.py", line 130, in __init__
raise Exception('Could not load icon {}'.format(app_icon))
Exception: Could not load icon ...\electrum\electrum\gui\icons\electrum.png
```
- wallet.get_receiving_addresses is guaranteed to exist (maybe it was only for HD wallets in the past)
- wallet.is_mine is stricter than wallet.adb.is_mine, usually we want the former
Previously it was only the actual commands that directly or indirectly verified
the password. This adds a check that runs for any command requiring a password.
related https://github.com/spesmilo/electrum/pull/9238
This is most useful if the user wants to import a significant number of keys,
as every invocation of `importprivkey` results in rewriting the wallet file to disk.
The API of "importprivkey" is left unchanged for the single privkey case.