cosmos / gaia

Cosmos Hub

Home Page:https://hub.cosmos.network

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Error when testing sending transactions on v18.1.0

Unded opened this issue · comments

Hi, I am testing an application for sending and tracking transaction. There were no problems when using v17.0.0 but after updating to the v18.1.0 I got the following error when sending transaction:

unable to get min gas price for denom uatom: error resolving denom

Full response:

txResponse_ = {Abci$TxResponse@18104} "txhash: "96109D05DB4478D99970FAFB7D3C8E0C07532A0C058A11F9BE66570D6AD7627D"\ncodespace: "undefined"\ncode: 1\nraw_log: "unable to get min gas price for denom uatom: error resolving denom"\n"
height_ = 0
txhash_ = "96109D05DB4478D99970FAFB7D3C8E0C07532A0C058A11F9BE66570D6AD7627D"
codespace_ = "undefined"
code_ = 1
data_ = ""
rawLog_ = "unable to get min gas price for denom uatom: error resolving denom"
logs_ = {Collections$EmptyList@18112}  size = 0
info_ = ""
gasWanted_ = 0
gasUsed_ = 0
tx_ = null
timestamp_ = ""
events_ = {Collections$EmptyList@18112}  size = 0
memoizedIsInitialized = -1
unknownFields = {UnknownFieldSet@18105} ""
memoizedSize = -1
memoizedHashCode = 0

The fee configuration in the "app.toml" file:

minimum-gas-prices = "0.025uatom"

globalfee = "0.025uatom"

bypass-min-fee-msg-types = [
    "/ibc.core.channel.v1.MsgRecvPacket",
    "/ibc.core.channel.v1.MsgAcknowledgement",
    "/ibc.applications.transfer.v1.MsgTransfer",
    "/ibc.core.client.v1.MsgUpdateClient",
    "/ibc.core.channel.v1.MsgTimeout",
    "/ibc.core.channel.v1.MsgTimeoutOnClose"
]

max-total-bypass-min-fee-msg-gas-usage = 1000000

Please let me know if I have missed any configuration properties, or if there is another case of the error

Thanks for opening the issue!

How are you bootstrapping your chain?

These config options are deprecated on v18.1.0:

minimum-gas-prices = "0.025uatom"

globalfee = "0.025uatom"

bypass-min-fee-msg-types = [
    "/ibc.core.channel.v1.MsgRecvPacket",
    "/ibc.core.channel.v1.MsgAcknowledgement",
    "/ibc.applications.transfer.v1.MsgTransfer",
    "/ibc.core.client.v1.MsgUpdateClient",
    "/ibc.core.channel.v1.MsgTimeout",
    "/ibc.core.channel.v1.MsgTimeoutOnClose"
]

max-total-bypass-min-fee-msg-gas-usage = 1000000

The feemarket module was added to gaia and made available in v18.1.0: https://github.com/skip-mev/feemarket/tree/main/x/feemarket

Depending on how you are bootstrapping your chain, you may need to adjust your genesis.json to initialize the feemarket params.

Try setting this in your genesis.json:

{
  "app_state": {
    ...
    "feemarket": {
    "params": {
      "alpha": "0.000000000000000000",
      "beta": "1.000000000000000000",
      "gamma": "0.000000000000000000",
      "delta": "0.000000000000000000",
      "min_base_gas_price": "0.005",  // can be 0
      "min_learning_rate": "0.125000000000000000",
      "max_learning_rate": "0.125000000000000000",
      "max_block_utilization": "30000000",
      "window": "1",
      "fee_denom": "uatom",   // set this to uatom
      "enabled": true,
      "distribute_fees": false
    },
    "state": {
      "base_gas_price": "0.005", // can be 0
      "learning_rate": "0.125000000000000000",
      "window": [
        "0"
      ],
      "index": "0"
    }
  },
  }
}

Please let us know if this resolves your issue and let us know if you think we should create specific docs for this issue.

Thank you!

Thank you for help!

I have updated the genesis.json and now everything works correctly.

How are you bootstrapping your chain?

I am using predefined app.toml and config.toml and then running the following commands:
1.

$ gaiad genesis collect-gentxs
$ gaiad start

Is it possible to prepare a configuration file for feemarket or add its configuration properties such as min_base_gas_price, fee_denom (and others) to the app.toml or config.toml file?

Unfortunately, It is not possible to add it to app.toml and config.toml because those are "on chain" parameters so they which cannot be configured through node specific configs.

I've checked the gaiad init command - it will create the feemarket section correctly. It might be enough to run gaiad init <moniker> and save the resulting genesis.json for future use.

You can also run gaiad init <moniker> and copy your custom app.toml and config.toml to the node config directory.

I see.
Thank you for the explanation!