Skip to content

Commit

Permalink
docs: lint errors and adr update
Browse files Browse the repository at this point in the history
  • Loading branch information
Lockwarr committed Feb 1, 2024
1 parent 94039bd commit 2875a35
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 0 additions & 4 deletions doc/adr/20231215-accept-fees-in-foreign-denoms.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,6 @@ message DenomTicker {

For each DEX that we work with, there will be a separate oracle and profit addresses. The denoms that we want to accept as fees will be defined for each DEX. For example, ATOM transferred from dex1 to nolus will have one denom, and ATOM transferred from dex2 to nolus will have another denom. The custom txFeeChecker will compare the denom that the user paid with the accepted denoms. When there is a match, we will know which oracle to query for the price. The deducted tax, not paid in the base asset, will be sent to the corresponding profit address from the parameters configuration.

For each dex that we work with, there will be a separate oracle and profit addresses.The denoms that we want to accept as fees will be defined for each dex.
For example, ATOM transferred from dex1 to nolus will have one denom, and ATOM transferred from dex2 to nolus will have another denom. The custom txFeeChecker will compare the denom that the user paid with the accepted denoms. When there is a match, we will know which oracle to query for the price. The deducted tax, not paid in the base asset, will be sent to the corresponding profit address from the parameters configuration.


### Positive Consequences

- Easier Onboarding for New Users: New users can participate in the nolus network without the necessity to acquire NLS initially. This reduces the barrier to entry and encourages experimentation with the protocol using existing funds.
Expand Down
4 changes: 2 additions & 2 deletions x/tax/keeper/custom_tx_fee_checker_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ func TestCustomTxFeeCheckerSuccessfulInUsdc(t *testing.T) {
require.Equal(t, sdk.NewCoins(sdk.NewInt64Coin(osmoAxlUSDCDenom, feeAmount)), feeCoins)
}

// Fail to pay fees in ibc/5DE... which represents axlUSDC from osmosis. Minimum gas prices set to unls. High gas -> fee amount not enough
// Fail to pay fees in ibc/5DE... which represents axlUSDC from osmosis. Minimum gas prices set to unls. High gas -> fee amount not enough.
func TestCustomTxFeeCheckerFailDueToHighGasPayingWithUSDC(t *testing.T) {
taxKeeper, ctx, mockWasmKeeper := keepertest.TaxKeeper(t, true, sdk.DecCoins{sdk.NewDecCoin("unls", sdk.NewInt(1))})
// create a new CustomTxFeeChecker
Expand All @@ -79,7 +79,7 @@ func TestCustomTxFeeCheckerFailDueToHighGasPayingWithUSDC(t *testing.T) {
require.Equal(t, "insufficient fees; got: 1.000000ibc/5DE4FCAF68AE40F81F738C857C0D95F7C1BC47B00FA1026E85C1DD92524D4A11 required: 5226075.194079ibc/5DE4FCAF68AE40F81F738C857C0D95F7C1BC47B00FA1026E85C1DD92524D4A11: insufficient fee", err.Error())
}

// Fail to pay fees in ibc/C4C... which represents OSMO. Minimum gas prices set to unls. High gas -> fee amount not enough
// Fail to pay fees in ibc/C4C... which represents OSMO. Minimum gas prices set to unls. High gas -> fee amount not enough.
func TestCustomTxFeeCheckerFailDueToHighGasPayingWithOSMO(t *testing.T) {
taxKeeper, ctx, mockWasmKeeper := keepertest.TaxKeeper(t, true, sdk.DecCoins{sdk.NewDecCoin("unls", sdk.NewInt(1))})
// create a new CustomTxFeeChecker
Expand Down

0 comments on commit 2875a35

Please sign in to comment.