0
I am trying to fund transaction with watch-only addresses:
$ bitcoin-cli getbalance '' 1 true
0.38810000
$ bitcoin-cli createrawtransaction '[]' '{"3Qxjvxyg9Pf67JU9MBNKVpJQ9rmALVnjt3":0.00001}'
020000000001e80300000000000017a914ff4432c8022b550a66b4c0a9c398962c3723ba278700000000
$ bitcoin-cli fundrawtransaction 020000000001e80300000000000017a914ff4432c8022b550a66b4c0a9c398962c3723ba278700000000 '{"includeWatching" : true}'
error code: -4
error message:
Insufficient funds
The idea is to sing the transaction later on different offline wallet.
Is this possible?
I can not use 'fundrawtransaction' directly on offline wallet, because it is offline and have no blockchain downloaded.
update:
yes, I know about potential problems with fee and change address. I am currently exploring possibilities.
1For
fundrawtransactionto work, you need more than just a watch-only address, as it needs to be able to predict the witness size needed to spend them. If you useimportaddressorimportmultiwith just an address, this is not possible. If you useimportpubkeyorimportmultiwith full keys/scripts, or with a descriptor, it will. You can test this by checkinggetaddressinfoon the addresses that the coins are currently assigned to. – Pieter Wuille – 2019-09-01T17:31:00.487I also noticed I can not sign transaction if blockchain is not synchronized – Nick – 2019-09-02T09:10:42.443