Sendfromaddress creates a 0 native units change transaction

+1 vote

We are using the native currency for Multichain, and using the api call 'sendfromaddress' somehow a 'change' transaction of amount 0 is created, which leads to a creation of a lot of unspent transactions which can't be used.

Outputs

IndexRedeemed at inputNativeTo addressScriptPubKey
0Not yet redeemed3432.561FxzaEpH4MpeMpfLfUkTm8AwDAz1ji2ZMpDUP HASH160 20:a428...f6af EQUALVERIFY CHECKSIG
1Not yet redeemed01LcUDr9bMNG6Kj4YtPtstVGZSHp4SKkQs4DUP HASH160 20:d71f...a797 EQUALVERIFY CHECKSIG

We're now skipping the utxo's with amount ve0 to craft new raw transactions, but it will be good to avoid the creation of transactions with amount 0 for native currency txs

 

 

asked Nov 14, 2016 by Federico Cardoso

1 Answer

0 votes
 
Best answer

In general all high level MultiChain APIs preserve a change UTXO for the sending address, otherwise all sorts of things can start breaking for permissions, streams, etc.... In your case try using raw transactions or the combineunspent API which can clean these up for you. There is also the auto combining functionality configured in the runtime parameters.

answered Nov 14, 2016 by MultiChain
...