namada icon indicating copy to clipboard operation
namada copied to clipboard

create basic disperse command for cli

Open colomvax opened this issue 1 year ago • 1 comments

Describe your changes

This PR is a suggestion of addition for a new command in the CLI for Namada, which could be very useful for a data protection oriented blockchain. It gets its inspiration from the "disperse" contract on Ethereum, which allows a user to send X to N addresses in one single transaction.

I know the implementation is not perfect/complete, because as it is, it sends N txs, instead of a single one, but Im not advanced enough in Rust or my comprehension of Namada codebase to go further than that. But I hope this provides a useful starter to add this command !

This would probably benefit from having its own VP and wasm, as it looks a lot like a simple transfer but to be able to run it in a single tx, it requires to wrap multiple tx inside the inner/wrapper txs. Not sure how to do that, way beyond me :smile:

Indicate on which release or other PRs this topic is based on

Checklist before merging to draft

  • [x] I have added a changelog
  • [x] Git history is in acceptable state

colomvax avatar Mar 22 '24 16:03 colomvax

Very nice, thank you for the contribution! We've recently added batch transaction support (many inner transactions in one) - I'm wondering, would that address the use-case you have in mind here?

cwgoes avatar May 22 '24 10:05 cwgoes

I believe this was implemented in #3459

grarco avatar Sep 09 '24 14:09 grarco

As @grarco said, this was implemented in https://github.com/anoma/namada/pull/3459, closing this! Thanks for the PR anyway!

Fraccaman avatar Sep 10 '24 11:09 Fraccaman