5.0.0 SendTransaction: CommitTransaction failed

I’m having a bit of difficulty sending transactions with the zcash-cli. I could really use a pointer to get back on track.

Environment:
Ubuntu
Linux dev 5.15.0-30-generic #31-Ubuntu SMP Thu May 5 10:00:34 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
zcashd 5.0.0 (Installed via Apt not from source)

zcash.conf:
testnet=1
addnode=testnet.z.cash
onlynet=ipv4
debug=rpc
walletrequirebackup=false
txindex=1
addressindex=1
spentindex=1
timestatmpindex=1

zcashd -reindex

Allow reindex to complete

zcash-cli stop
zcashd -rescan

Recan “might” actually be happening along with reindex but just to be thorough do it anyway

zcash-cli stop
zcashd

zcash-cli z_getbalance tmGJCHMgwVoeodnoF8GKKAVADWudaxQsRLb
0.32211630

Verify enough test coins

zcash-cli getblockcount; zcash-cli z_sendmany “tmGJCHMgwVoeodnoF8GKKAVADWudaxQsRLb” ‘[{“address”: “tmE6pNLKq6DpCJygN9JLMCSB8sZJVJjVHL9”, “amount”: 0.00001}]’ 1 0.00001 “NoPrivacy”

1883235
opid-14ef1147-ce4a-49e3-8929-998bd512668a

2022-05-19T15:30:41.676725Z DEBUG rpc: ThreadRPCServer method=getblockcount
2022-05-19T15:30:41.681358Z DEBUG rpc: ThreadRPCServer method=z_sendmany
2022-05-19T15:30:41.707339Z INFO main: CommitTransaction:
CTransaction(hash=f597d18e20, ver=5, fOverwintered=1, nVersionGroupId=26a7270a, vin.size=1, vout.size=2, nLockTime=0, nExpiryHeight=1883276, valueBalanceSapling=0, vSaplingSpend.size=0, vSaplingOutput.size=0, nConsensusBranchId=c2d6d0b4, valueBalanceOrchard=0, vOrchardAction.size=0)
CTxIn(COutPoint(e518abceb7, 0), scriptSig=47304402203c9c9c4abae80d)
CTxOut(nValue=0.00001000, scriptPubKey=76a914302039504ae4b947afca3823)
CTxOut(nValue=0.13368221, scriptPubKey=76a9147618ff0faaaba7314be4020e)
2022-05-19T15:30:41.707442Z INFO main: AddToWallet f597d18e2096d75e59860ed07774a028907b3b15673f047f27e931518645255b new
2022-05-19T15:30:41.717620Z INFO main: CommitTransaction(): Error: Transaction not valid
2022-05-19T15:30:41.740165Z INFO main: opid-14ef1147-ce4a-49e3-8929-998bd512668a: z_sendmany finished (status=failed, error=SendTransaction: CommitTransaction failed)

I tired first going from Transparent to UA address on 5.0.0 and got this error. I fell back to transparent but I get the same errors in the logs as above.

What can I try next to trouble shoot in order to complete a z_sendmany?

Dennis

1 Like

By any chance, do you get any additional info from

zcash-cli z_getoperationstatus '["opid-14ef1147-ce4a-49e3-8929-998bd512668a"]' ?

2 Likes

Yes. Not much different than what is in the logs. Retry the z_sendmany and then z_getoperationstatus yields:

[
{
“id”: “opid-9c8e1f90-323a-494a-853c-f0574ccddd6c”,
“status”: “failed”,
“creation_time”: 1652977369,
“error”: {
“code”: -4,
“message”: “SendTransaction: CommitTransaction failed”
},
“method”: “z_sendmany”,
“params”: {
“fromaddress”: “tmGJCHMgwVoeodnoF8GKKAVADWudaxQsRLb”,
“amounts”: [
{
“address”: “tmE6pNLKq6DpCJygN9JLMCSB8sZJVJjVHL9”,
“amount”: 0.00001
}
],
“minconf”: 1,
“fee”: 1e-05
}
}
]

1 Like

I sent tmE6pNLKq6DpCJygN9JLMCSB8sZJVJjVHL9 some funds just to test your above syntax and privacy setting and they completed successfully for me. I’m curious to know if you received these:

z2t e3aaada4fed84e2cc3ca06ca941714904bb93d30b3c205d0ebfc01488e40a5ad
t2t 88683b9cbffcbbe4a118bb15bd69d7a8eb4477f3b92585eb14e2c19716c41ea3

1 Like

Yes for total of 0.00002000

1 Like

zcash-cli z_listreceivedbyaddress tmE6pNLKq6DpCJygN9JLMCSB8sZJVJjVHL9
[
{
“pool”: “transparent”,
“txid”: “6e49edc2fc1011aee4e88940b2180497adc22862e4cdbc1fd0e8cba74938d811”,
“amount”: 0.00001000,
“amountZat”: 1000,
“outindex”: 0,
“confirmations”: 21,
“change”: false,
“blockheight”: 1883284,
“blockindex”: 1,
“blocktime”: 1652977722
},
{
“pool”: “transparent”,
“txid”: “88683b9cbffcbbe4a118bb15bd69d7a8eb4477f3b92585eb14e2c19716c41ea3”,
“amount”: 0.00001000,
“amountZat”: 1000,
“outindex”: 0,
“confirmations”: 13,
“change”: false,
“blockheight”: 1883292,
“blockindex”: 2,
“blocktime”: 1652978584
}
]

1 Like

zcash-cli z_viewtransaction 88683b9cbffcbbe4a118bb15bd69d7a8eb4477f3b92585eb14e2c19716c41ea3
{
“txid”: “88683b9cbffcbbe4a118bb15bd69d7a8eb4477f3b92585eb14e2c19716c41ea3”,
“spends”: [
],
“outputs”: [
]
}

This looks about right to me… I’m not sure what the next step is. Will jump back in here if I have a eureka moment.

Fwiw I built from source, I have no experience using the apt install.

Going to build from source and reindex and rescan on my main workstation. Also, installing fresh on a second machine - probably just let this second machine pull down chain fresh on 5 – maybe I have a corruption some place but I figured if I did reindex or rescan would have choked still I’ll let that second machine serve as a kind of “control” while I trouble shoot this.

Anyway, If I figure out what is going on I’ll post as well.

In the meantime @BrunchTime you continue to be handsome AND benevolent!
:slight_smile:

2 Likes

Here was a similar issue, I can’t remember if they’re related but I seem to remember maybe this one (missing witness) coming after that one (committransaction)

2 Likes

Backed up the wallet.dat from ~./zcash/testnet3, deleted ./zcash/testnet3, let it resync overnight, restored wallet.dat to ~./zcash/testnet3.

Now I’m good to go and command executes as expected.

Wish I had more insight into what was getting in the way. Gotta be PEBKAC but what more specifically I just can’t say.

Thanks again @BrunchTime and @Autotunafish. Really appreciate your help and will try to pay it forward.

2 Likes