Non-descriptive error logging for too long memo
The following error is issued by hermes version v1.10.3 after trying to start the process with a config that has a memo for any chain longer than 50 characters.
The Hermes configuration file at path '/home/deploy/.hermes/config.toml' is invalid, reason: parse error: invalid CosmosSdk config: invalid length 52, expected a string length of at most 50 for key `chains` at line 128 column 1 Please see the example configuration for detailed information about the supported configuration options: https://github.com/informalsystems/hermes/blob/master/config.toml
This error however seems to indicate that too many chains are configured which is not at all the case.
-- proposed solution better describe the actual problem with the config
Reproducing config:
# The global section has parameters that apply globally to the relayer operation.
[global]
log_level = 'warn'
# Specify the mode to be used by the relayer. [Required]
[mode]
# Specify the client mode.
[mode.clients]
enabled = true
refresh = true
misbehaviour = false
# Specify the connections mode.
[mode.connections]
enabled = false
# Specify the channels mode.
[mode.channels]
enabled = false
# Specify the packets mode.
[mode.packets]
enabled = true
clear_interval = 1000
clear_on_start = true
tx_confirmation = true
# The REST section defines parameters for Hermes' built-in RESTful API.
# https://hermes.informal.systems/rest.html
[rest]
enabled = true
host = '0.0.0.0'
port = 3001
[telemetry]
enabled = true
host = '0.0.0.0'
port = 4001
[telemetry.buckets]
latency_submitted = { start = 5000, end = 10000, buckets = 10 }
latency_confirmed = { start = 5000, end = 10000, buckets = 10 }
# Begin block: andromeda
[[chains]]
id = 'andromeda-1'
rpc_addr = 'http://5'
grpc_addr = 'http://5'
event_source = { mode = "push", url = 'ws:/, batch_delay = '5000ms' }
rpc_timeout = '20s'
account_prefix = 'andromeda'
trusted_node = true
ccv_consumer_chain = false
key_name = 'default'
store_prefix = 'ibc'
default_gas = 125000
max_gas = 12000000
gas_price = { price = 0.0, denom = 'uandr' }
gas_multiplier = 1.25
max_msg_num = 30
max_tx_size = 2097152
clock_drift = '5s'
max_block_time = '30s'
trusting_period = '14days'
client_refresh_rate = '1/3'
trust_threshold = { numerator = '2', denominator = '3' }
address_type = { derivation = 'cosmos' }
memo_prefix = 'Relayed with 💜 by Lavender.Five Nodes 🐝'
fee_granter = ''
[chains.packet_filter]
policy = 'allow'
list = [
['transfer', 'channel-2'],
['transfer', 'channel-12'],
['transfer', 'channel-5'],
['transfer', 'channel-11'],
['transfer', 'channel-13'],
]
# End block: andromeda
# Begin block: akash
[[chains]]
id = 'akashnet-2'
rpc_addr = 'http://'
grpc_addr = 'http://'
event_source = { mode = "push", url = 'ws://websocket', batch_delay = '5000ms' }
rpc_timeout = '20s'
account_prefix = 'akash'
trusted_node = true
ccv_consumer_chain = false
key_name = 'default'
store_prefix = 'ibc'
default_gas = 125000
max_gas = 12000000
gas_price = { price = 0.00025, denom = 'uakt' }
gas_multiplier = 1.25
max_msg_num = 30
max_tx_size = 2097152
clock_drift = '5s'
max_block_time = '30s'
trusting_period = '7days'
client_refresh_rate = '1/3'
trust_threshold = { numerator = '2', denominator = '3' }
address_type = { derivation = 'cosmos' }
memo_prefix = 'Relayed with 💜 by Lavender.Five Nodes 🐝 - EXTRA TEXT'
fee_granter = ''
[chains.packet_filter]
policy = 'allow'
list = [
['transfer', 'channel-9'],
['transfer', 'channel-35'],
['transfer', 'channel-43'],
['transfer', 'channel-56'],
['transfer', 'channel-61'],
]
# End block: akash