![coinbase transaction – bitcoin-cli generatetoaddress has 2 outputs coinbase transaction – bitcoin-cli generatetoaddress has 2 outputs](https://cryptohq.org/wp-content/uploads/https://cdn.sstatic.net/Sites/bitcoin/Img/apple-touch-icon@2.png?v=b4864ba760f1)
[ad_1]
I’ve the next drawback:
presently i’m testing in my native regtest
I generated the next cb-tx for block at peak 119: 01000000010000000000000000000000000000000000000000000000000000000000000000ffffffff03027700ffffffff0158bf122a010000001976a914a08da9e35ab58e957204703da9d48967ddd1703b88ac00000000
there are some tx within the mempool
for the opposite tx i take the txid from the getblocktemplate request
I reverse the byte order for all of these and for the txid of the cbtx aswell.
nonetheless, i get the next error: bad-txnmrklroot
when i generate a block utilizing generatetoaddress in regtest, then use getblock and run my merkle operate over the txids, the merkle root is appropriate which implies it’s a situation with the coinbase txid
i noticed that the coinbase tx from the generatetoaddress rpc name has a second output with 0 satoshis.
is it attainable to take away this second output so i can take a look at additional?
perhaps somebody had the identical situation.
thanks prematurely.
[ad_2]