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

feat(vara,gear-bank): Split gas and fees to author/treasury #3652

Open
wants to merge 35 commits into
base: master
Choose a base branch
from

Conversation

ukint-vs
Copy link
Member

@ukint-vs ukint-vs commented Jan 10, 2024

  • Implement splitting of the tx fees to the block author and to the Treasury.
  • Add splitting gas fees in gear-bank.
  • Add SplitGas and SplitTxFeeRatio in gear-bank config
    @gear-tech/dev

@ukint-vs ukint-vs added the A0-pleasereview PR is ready to be reviewed by the team label Jan 10, 2024
@ukint-vs ukint-vs self-assigned this Jan 10, 2024
runtime/common/src/lib.rs Outdated Show resolved Hide resolved
runtime/common/src/lib.rs Outdated Show resolved Hide resolved
Copy link
Member

@breathx breathx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I'm not mistaken, we were talking about gas fees, not tx-s (or not only tx-s).
And I'd make this constant customisable with governance not only on upgrades.

Furthermore, this question is still considering, so pls don't merge yet.

@breathx breathx added A3-gotissues PR occurred to have issues after the review A5-dontmerge PR should not be merged yet and removed A0-pleasereview PR is ready to be reviewed by the team labels Jan 16, 2024
@ukint-vs ukint-vs added the A1-inprogress Issue is in progress or PR draft is not ready to be reviewed label Jan 30, 2024
@breathx
Copy link
Member

breathx commented Feb 6, 2024

Is it ready for review?

@ukint-vs
Copy link
Member Author

ukint-vs commented Feb 6, 2024

Is it ready for review?

Not yet. Need final touches and tests

@ukint-vs ukint-vs added A0-pleasereview PR is ready to be reviewed by the team and removed A1-inprogress Issue is in progress or PR draft is not ready to be reviewed labels Feb 11, 2024
@ukint-vs ukint-vs changed the title feat(vara): Split fees 50/50, author/treasury feat(vara,gear-bank): Split fees 50/50, author/treasury Feb 11, 2024
@breathx
Copy link
Member

breathx commented Feb 12, 2024

Fix tests to pass CI pls @ukint-vs

@breathx
Copy link
Member

breathx commented May 14, 2024

To be reviewed once fetched master

@breathx
Copy link
Member

breathx commented May 26, 2024

@ukint-vs pls finalise this one

@ukint-vs ukint-vs changed the title feat(vara,gear-bank): Split fees 50/50, author/treasury feat(vara,gear-bank): Split gas and fees to author/treasury May 28, 2024
@ukint-vs ukint-vs added A0-pleasereview PR is ready to be reviewed by the team and removed A1-inprogress Issue is in progress or PR draft is not ready to be reviewed A3-gotissues PR occurred to have issues after the review labels May 29, 2024
Copy link
Member

@breathx breathx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On gear bank side, please perform ratio multiplying only once before transfer
Otherwise, great done 👍🏻

pallets/gear-bank/src/lib.rs Outdated Show resolved Hide resolved
pallets/gear-bank/src/tests.rs Outdated Show resolved Hide resolved
);
assert_eq!(Balances::free_balance(alice.to_account_id()), STASH);

DealWithFees::on_unbalanceds(vec![fee, tip].into_iter());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shouldn't the case be covered by pallet transaction payment?

runtime/vara/src/lib.rs Show resolved Hide resolved
@breathx breathx added A2-mergeoncegreen PR is ready to merge after CI passes A3-gotissues PR occurred to have issues after the review and removed A0-pleasereview PR is ready to be reviewed by the team A5-dontmerge PR should not be merged yet labels Jun 11, 2024
@breathx
Copy link
Member

breathx commented Jul 7, 2024

Actualise branch and resolve opened discussions, please @ukint-vs

@ukint-vs ukint-vs added A0-pleasereview PR is ready to be reviewed by the team and removed A3-gotissues PR occurred to have issues after the review A2-mergeoncegreen PR is ready to merge after CI passes labels Jul 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A0-pleasereview PR is ready to be reviewed by the team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants