Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow modules to incentivize packets instead of assuming it is a user account #1329

Closed
3 tasks
crodriguezvega opened this issue May 1, 2022 · 3 comments · Fixed by #1397
Closed
3 tasks
Assignees
Labels

Comments

@crodriguezvega
Copy link
Contributor

crodriguezvega commented May 1, 2022

This would require:

@crodriguezvega crodriguezvega added needs discussion Issues that need discussion before they can be worked on 29-fee labels May 1, 2022
@crodriguezvega crodriguezvega added this to the Fee middleware RC milestone May 1, 2022
@crodriguezvega crodriguezvega moved this to Todo in ibc-go May 1, 2022
@AdityaSripal AdityaSripal changed the title Should we allow modules to incentivize packets instead of assuming it is a user account? Allow modules to incentivize packets instead of assuming it is a user account May 2, 2022
@AdityaSripal
Copy link
Member

I think this is worth doing given that one use case that came up in discussions around this feature was a module paying for fees on their chain. This will entail changing any call SendCoinsFromModuleToAccount and SendCoinsFromAccountToModule to be SendCoins.

We will need to add check in each case that the receiver of the coins is not a blocked address.

cc: @colin-axner

@colin-axner
Copy link
Contributor

To check if we need to adjust the incentivizing address to be a sdk.AccAddress, try to write a test which uses a module to incentivize the packet

@seantking seantking self-assigned this May 11, 2022
@crodriguezvega crodriguezvega removed the needs discussion Issues that need discussion before they can be worked on label May 16, 2022
@colin-axner colin-axner moved this from Todo to In progress in ibc-go May 16, 2022
@seantking
Copy link
Contributor

Spoke with @AdityaSripal & @colin-axner after writing a test. It turns out this already works out of the box:

This function already does what we were planning on doing:
https://github.com/cosmos/cosmos-sdk/blob/b6478026c4e8c5f03c7e6c6f726a60debb9bbfac/x/bank/keeper/keeper.go#L318

@crodriguezvega crodriguezvega moved this from In progress to In review in ibc-go May 18, 2022
@damiannolan damiannolan removed their assignment Jun 20, 2022
Repository owner moved this from In review to Done in ibc-go Jun 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

5 participants