Closed lkthomas closed 4 years ago
probably a duplicate of #2976 are you sending to a segwit address?
no, I am sending to a standard wallet address.
Is this a duplicate of #2738 and #2903?
EDIT: On master, I have now tested creating and signing transactions with a 2-of-2 wallet on Testnet with old (non-segwit) p2sh inputs, with both Trezor being first and last signer (though not Trezor being both).
@lkthomas you probably need to upgrade your firmware
I'm getting this on Keepkey sending to a P2SH address from a normal 1-address. If OP truly used Trezor wallet and not Keepkey it would seem odd to have a bug in both firmwares as they have drifted quite a bit, but it could be a cut-n-paste I guess.
@lkthomas are you using latest trezor firmware?
One more thing - same KeepKey firmware sends fine to that address with Electron Cash under same circumstances. So it seems likely this is an Electrum issue.
@lkthomas Can you re-test this in Electrum 3.0.x?
@kyuupichan I'm guessing you're already trying on 3.0?
Also, note that OP is trying to spend from a P2SH address (I'm assuming based on [CoinChooserOldestFirst] change: [(0, u'2MuD9bCeGay5nx1cUKhzgErZAPApYnRqP1z', 129899600)]
), not sure if it is p2sh-multisig or p2sh-segwit or something else. So if it is the same bug, then it is a quite broad one.
Max56 in #electrum IRC reported the "same".
He had been using Electrum 3.0.1, with a KeepKey, on MacOS.
He had a single signer standard wallet, so not multisig, not segwit, ordinary 1...
addresses.
The destination addresses were also 1...
addresses.
As far as I could gather from him, it sounded as if not even the parent txs of the inputs had segwit inputs.
Hence, to me, it sounds like KeepKey support is currently fully broken.
EDIT: He claims it works when using Electrum 2.9.3. He also claims it works for some (?) txs on 3.0.1 but I couldn't get enough debugging info on this.
I've now bought a KeepKey and tracked this down to https://github.com/spesmilo/electrum/commit/020f0637d7d8ec412df3762cfa9485a36574d274. KeepKey is unable to send to p2sh outputs due to that change.
This aligns with what @kyuupichan reported.
I think python-trezor and python-keepkey probably diverged at some point in this specific regard, and my guess is that if @lkthomas was using a Trezor not a KeepKey, then his trezorlib version might have been old enough to not have the divergent change.
No idea about the report from Max56.
EDIT: I've just noticed that the report by @lkthomas predates the commit by 3 days, haha. Not sure about his problem either then.
I think this issue is severely outdated at this point and probably does not apply anymore.
Electrum 2.9.3 --testnet Ubuntu 14.04 64bit
[profiler] estimated_size 0.0002 [CoinChooserOldestFirst] change: [(0, u'2MuD9bCeGay5nx1cUKhzgErZAPApYnRqP1z', 129899600)] [CoinChooserOldestFirst] using 1 inputs [CoinChooserOldestFirst] using buckets: [u'60f1f864f4a157f71388b98e73c98d400620245d5d0b2446b7307e5eb3eaea29:0'] [profiler] estimated_size 0.0006 [profiler] estimated_size 0.0008 [14.3.140.101] failed to connect timed out [DeviceMgr] getting client for keystore [DeviceMgr] scanning devices... [DeviceMgr] end client for keystore Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/electrum_gui/qt/util.py", line 582, in run result = task.task() File "/usr/local/lib/python2.7/dist-packages/electrum/wallet.py", line 1141, in sign_transaction k.sign_transaction(tx, password) File "/usr/local/lib/python2.7/dist-packages/electrum_plugins/trezor/plugin.py", line 66, in sign_transaction self.plugin.sign_transaction(self, tx, prev_tx, xpub_path) File "/usr/local/lib/python2.7/dist-packages/electrum_plugins/trezor/plugin.py", line 242, in sign_transaction signed_tx = client.sign_tx(self.get_coin_name(), inputs, outputs, lock_time=tx.locktime)[1] File "/usr/local/lib/python2.7/dist-packages/electrum_plugins/trezor/clientbase.py", line 221, in wrapped return func(self, *args, kwargs) File "/usr/local/lib/python2.7/dist-packages/trezorlib/client.py", line 158, in wrapped_f return f(*args, *kwargs) File "/usr/local/lib/python2.7/dist-packages/trezorlib/client.py", line 824, in sign_tx res = self.call(proto.TxAck(tx=msg)) File "/usr/local/lib/python2.7/dist-packages/trezorlib/client.py", line 158, in wrapped_f return f(args, kwargs) File "/usr/local/lib/python2.7/dist-packages/trezorlib/client.py", line 201, in call msg = handler(resp) File "/usr/local/lib/python2.7/dist-packages/electrum_plugins/trezor/clientbase.py", line 35, in callback_Failure raise RuntimeError(msg.message) RuntimeError: Failed to compile output