Skip to content

Commit

Permalink
Merge branch 'main' into batch-undelegation-int-tests-2
Browse files Browse the repository at this point in the history
  • Loading branch information
sampocs committed Aug 28, 2024
2 parents 96ac981 + 930d4eb commit 8185fe5
Show file tree
Hide file tree
Showing 19 changed files with 234 additions and 184 deletions.
2 changes: 1 addition & 1 deletion deps/gaia
Submodule gaia updated 582 files
2 changes: 1 addition & 1 deletion dockernet/config/relayer_config_stride.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ chains:
account-prefix: cosmos
keyring-backend: test
gas-adjustment: 1.3
gas-prices: 0.02uatom
gas-prices: 1ufee
coin-type: 118
debug: false
timeout: 20s
Expand Down
19 changes: 13 additions & 6 deletions dockernet/dockerfiles/Dockerfile.gaia
Original file line number Diff line number Diff line change
@@ -1,17 +1,24 @@
FROM golang:1.20-alpine3.16 AS builder
FROM golang:1.22-alpine AS builder

WORKDIR /opt

RUN apk add --update curl make git libc-dev bash gcc linux-headers eudev-dev python3
RUN apk add --update curl make git libc-dev bash gcc linux-headers eudev-dev ca-certificates build-base git

ENV COMMIT_HASH=v12.0.0-rc0
ENV COMMIT_HASH=v18.1.0

RUN git clone https://github.com/cosmos/gaia \
&& cd gaia \
&& git checkout $COMMIT_HASH \
&& CGO_ENABLED=0 make install
&& git checkout $COMMIT_HASH

FROM alpine:3.16
WORKDIR /opt/gaia

RUN WASMVM_VERSION=$(cat go.mod | grep github.com/CosmWasm/wasmvm | awk '{print $2}') \
&& wget https://github.com/CosmWasm/wasmvm/releases/download/$WASMVM_VERSION/libwasmvm_muslc.$(uname -m).a \
-O /lib/libwasmvm_muslc.a

RUN CGO_ENABLED=1 BUILD_TAGS="muslc linkstatic" LINK_STATICALLY=true LEDGER_ENABLED=false make install

FROM alpine:3.17
COPY --from=builder /go/bin/gaiad /usr/local/bin/
RUN apk add bash vim \
&& addgroup -g 1000 gaia \
Expand Down
21 changes: 13 additions & 8 deletions dockernet/src/init_chain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ STAKE_TOKENS=${STAKE_TOKENS}${MICRO_DENOM_UNITS}
ADMIN_TOKENS=${ADMIN_TOKENS}${MICRO_DENOM_UNITS}
USER_TOKENS=${USER_TOKENS}${MICRO_DENOM_UNITS}

FEES=1000000000ufee
GENESIS_CMD=$($BINARY 2>&1 | grep -q "genesis-related subcommands" && echo "genesis" || echo "")

set_stride_epochs() {
genesis_config=$1

Expand Down Expand Up @@ -127,11 +130,13 @@ set_host_genesis() {
sed -i -E 's|"downtime_jail_duration": "600s"|"downtime_jail_duration": "10s"|g' $genesis_config
sed -i -E 's|"slash_fraction_downtime": "0.010000000000000000"|"slash_fraction_downtime": "0.050000000000000000"|g' $genesis_config

# LSM params
# LSM and feemarket params
if [[ "$CHAIN" == "GAIA" ]]; then
jq '.app_state.staking.params.validator_bond_factor = $newVal' --arg newVal "$LSM_VALIDATOR_BOND_FACTOR" $genesis_config > json.tmp && mv json.tmp $genesis_config
jq '.app_state.staking.params.validator_liquid_staking_cap = $newVal' --arg newVal "$LSM_VALIDATOR_LIQUID_STAKING_CAP" $genesis_config > json.tmp && mv json.tmp $genesis_config
jq '.app_state.staking.params.global_liquid_staking_cap = $newVal' --arg newVal "$LSM_GLOBAL_LIQUID_STAKING_CAP" $genesis_config > json.tmp && mv json.tmp $genesis_config

jq '.app_state.feemarket.params.fee_denom = $newVal' --arg newVal "ufee" $genesis_config > json.tmp && mv json.tmp $genesis_config
fi
}

Expand Down Expand Up @@ -161,7 +166,7 @@ add_genesis_account() {

create_account "$account_name" "$mnemonic"
address=$($MAIN_CMD keys show $account_name --keyring-backend test -a | tr -cd '[:alnum:]._-')
$MAIN_CMD add-genesis-account ${address} ${amount}${DENOM}
$MAIN_CMD $GENESIS_CMD add-genesis-account ${address} ${amount}${DENOM},${FEES}
}

MAIN_ID=1 # Node responsible for genesis and persistent_peers
Expand Down Expand Up @@ -225,7 +230,7 @@ for (( i=1; i <= $NUM_NODES; i++ )); do
if [[ "$CHAIN" == "NOBLE" ]]; then
genesis_coins=${genesis_coins},${VAL_TOKENS}${USDC_DENOM}
fi
$cmd add-genesis-account ${val_addr} ${genesis_coins}
$cmd $GENESIS_CMD add-genesis-account ${val_addr} ${genesis_coins},${FEES}

# Copy over the provider stride validator keys to the provider (in the event
# that we are testing ICS)
Expand All @@ -238,7 +243,7 @@ for (( i=1; i <= $NUM_NODES; i++ )); do

# Only generate the validator txs for host chains
if [[ "$CHAIN" != "STRIDE" && "$CHAIN" != "HOST" ]]; then
$cmd gentx $val_acct ${STAKE_TOKENS}${DENOM} --chain-id $CHAIN_ID --keyring-backend test &> /dev/null
$cmd $GENESIS_CMD gentx $val_acct ${STAKE_TOKENS}${DENOM} --chain-id $CHAIN_ID --keyring-backend test &> /dev/null
fi

# Get the endpoint and node ID
Expand All @@ -257,7 +262,7 @@ for (( i=1; i <= $NUM_NODES; i++ )); do
MAIN_GENESIS=$genesis_json
else
# also add this account and it's genesis tx to the main node
$MAIN_CMD add-genesis-account ${val_addr} ${VAL_TOKENS}${DENOM}
$MAIN_CMD $GENESIS_CMD add-genesis-account ${val_addr} ${VAL_TOKENS}${DENOM},${FEES}
if [ -d "${STATE}/${node_name}/config/gentx" ]; then
cp ${STATE}/${node_name}/config/gentx/*.json ${STATE}/${MAIN_NODE_NAME}/config/gentx/
fi
Expand Down Expand Up @@ -319,7 +324,7 @@ else
if [ "$CHAIN" == "NOBLE" ]; then
echo "$NOBLE_AUTHORITHY_MNEMONIC" | $MAIN_CMD keys add authority --recover --keyring-backend test >> $KEYS_LOGS 2>&1
AUTHORITHY_ADDRESS=$($MAIN_CMD keys show authority --keyring-backend test -a | tr -cd '[:alnum:]._-')
$MAIN_CMD add-genesis-account ${AUTHORITHY_ADDRESS} ${VAL_TOKENS}${DENOM},${VAL_TOKENS}${USDC_DENOM}
$MAIN_CMD $GENESIS_CMD add-genesis-account ${AUTHORITHY_ADDRESS} ${VAL_TOKENS}${DENOM},${VAL_TOKENS}${USDC_DENOM}

sed -i -E 's|"authority": ""|"authority":"'${AUTHORITHY_ADDRESS}'"|g' $genesis_json
sed -i -E 's|"mintingDenom": null|"mintingDenom":{"denom":"'${DENOM}'"}|g' $genesis_json
Expand All @@ -335,12 +340,12 @@ fi
# the account should live on both stride and the host chain
echo "$USER_MNEMONIC" | $MAIN_CMD keys add $USER_ACCT --recover --keyring-backend=test >> $KEYS_LOGS 2>&1
USER_ADDRESS=$($MAIN_CMD keys show $USER_ACCT --keyring-backend test -a)
$MAIN_CMD add-genesis-account ${USER_ADDRESS} ${USER_TOKENS}${DENOM}
$MAIN_CMD $GENESIS_CMD add-genesis-account ${USER_ADDRESS} ${USER_TOKENS}${DENOM},${FEES}

# Only collect the validator genesis txs for host chains
if [[ "$CHAIN" != "STRIDE" && "$CHAIN" != "HOST" ]]; then
# now we process gentx txs on the main node
$MAIN_CMD collect-gentxs &> /dev/null
$MAIN_CMD $GENESIS_CMD collect-gentxs &> /dev/null
fi

# wipe out the persistent peers for the main node (these are incorrectly autogenerated for each validator during collect-gentxs)
Expand Down
2 changes: 1 addition & 1 deletion dockernet/src/register_host.sh
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ for (( i=1; i <= $NUM_VALS; i++ )); do
if [[ "$i" == "1" ]]; then
echo "$CHAIN - Submitting validator bonds..."
fi
$GAIA_MAIN_CMD tx staking validator-bond $delegate_val --from ${VAL_PREFIX}${i} -y | TRIM_TX
$GAIA_MAIN_CMD tx staking validator-bond $delegate_val --from ${VAL_PREFIX}${i} -y --fees 1000000ufee | TRIM_TX
fi
done

Expand Down
46 changes: 17 additions & 29 deletions dockernet/tests/integration_tests.bats
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ setup_file() {
REDEEM_AMOUNT=10000
PACKET_FORWARD_STAKE_AMOUNT=300000

HOST_FEES="--fees 1000000ufee"

# HELPER FUNCTIONS
DECADD () {
echo "scale=2; $1+$2" | bc
Expand Down Expand Up @@ -98,7 +100,7 @@ setup_file() {

# do IBC transfer
$STRIDE_MAIN_CMD tx ibc-transfer transfer transfer $STRIDE_TRANSFER_CHANNEL $HOST_VAL_ADDRESS ${TRANSFER_AMOUNT}${STRIDE_DENOM} --from $STRIDE_VAL -y
$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL $(STRIDE_ADDRESS) ${TRANSFER_AMOUNT}${HOST_DENOM} --from $HOST_VAL -y
$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL $(STRIDE_ADDRESS) ${TRANSFER_AMOUNT}${HOST_DENOM} --from $HOST_VAL -y $HOST_FEES

WAIT_FOR_BLOCK $STRIDE_LOGS 8

Expand Down Expand Up @@ -177,11 +179,11 @@ setup_file() {
validator_address=$(GET_VAL_ADDR $CHAIN_NAME 1)

# delegate on the host chain
$HOST_MAIN_CMD tx staking delegate $validator_address ${TRANSFER_AMOUNT}${HOST_DENOM} --from $USER_ACCT -y
$HOST_MAIN_CMD tx staking delegate $validator_address ${TRANSFER_AMOUNT}${HOST_DENOM} --from $USER_ACCT -y $HOST_FEES
WAIT_FOR_BLOCK $STRIDE_LOGS 2

# tokenize shares
$HOST_MAIN_CMD tx staking tokenize-share $validator_address ${TRANSFER_AMOUNT}${HOST_DENOM} $staker_address_on_host --from $USER_ACCT -y --gas 1000000
$HOST_MAIN_CMD tx staking tokenize-share $validator_address ${TRANSFER_AMOUNT}${HOST_DENOM} $staker_address_on_host --from $USER_ACCT -y --gas 1000000 $HOST_FEES
WAIT_FOR_BLOCK $STRIDE_LOGS 2

# get the record id from the tokenized share record
Expand All @@ -190,7 +192,7 @@ setup_file() {
# transfer LSM tokens to stride
lsm_token_denom=${validator_address}/${record_id}
$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL \
$staker_address_on_stride ${TRANSFER_AMOUNT}${lsm_token_denom} --from $USER_ACCT -y
$staker_address_on_stride ${TRANSFER_AMOUNT}${lsm_token_denom} --from $USER_ACCT -y $HOST_FEES

WAIT_FOR_BLOCK $STRIDE_LOGS 8

Expand Down Expand Up @@ -257,14 +259,8 @@ setup_file() {
sttoken_balance_start=$($STRIDE_MAIN_CMD q bank balances $(STRIDE_ADDRESS) --denom st$HOST_DENOM | GETBAL)

# Send the IBC transfer with the JSON memo
transfer_msg_prefix="$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL"
if [[ "$CHAIN_NAME" == "GAIA" ]]; then
# For GAIA (ibc-v3), pass the memo into the receiver field
$transfer_msg_prefix "$memo" ${PACKET_FORWARD_STAKE_AMOUNT}${HOST_DENOM} --from $HOST_VAL -y
else
# For all other hosts (ibc-v5), pass an address for a receiver and the memo in the --memo field
$transfer_msg_prefix $(STRIDE_ADDRESS) ${PACKET_FORWARD_STAKE_AMOUNT}${HOST_DENOM} --memo "$memo" --from $HOST_VAL -y
fi
$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL \
$(STRIDE_ADDRESS) ${PACKET_FORWARD_STAKE_AMOUNT}${HOST_DENOM} --memo "$memo" --from $HOST_VAL -y $HOST_FEES

# Wait for the transfer to complete
WAIT_FOR_BALANCE_CHANGE STRIDE $(STRIDE_ADDRESS) st$HOST_DENOM
Expand All @@ -282,14 +278,8 @@ setup_file() {
stibctoken_balance_start=$($HOST_MAIN_CMD q bank balances $HOST_VAL_ADDRESS --denom $IBC_STTOKEN 2>/dev/null | GETBAL)

# Send the IBC transfer with the JSON memo
transfer_msg_prefix="$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL"
if [[ "$CHAIN_NAME" == "GAIA" ]]; then
# For GAIA (ibc-v3), pass the memo into the receiver field
$transfer_msg_prefix "$memo" ${PACKET_FORWARD_STAKE_AMOUNT}${HOST_DENOM} --from $HOST_VAL -y
else
# For all other hosts (ibc-v5), pass an address for a receiver and the memo in the --memo field
$transfer_msg_prefix $(STRIDE_ADDRESS) ${PACKET_FORWARD_STAKE_AMOUNT}${HOST_DENOM} --memo "$memo" --from $HOST_VAL -y
fi
$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL \
$(STRIDE_ADDRESS) ${PACKET_FORWARD_STAKE_AMOUNT}${HOST_DENOM} --memo "$memo" --from $HOST_VAL -y $HOST_FEES

# Wait for the transfer to complete
WAIT_FOR_BALANCE_CHANGE $CHAIN_NAME $HOST_VAL_ADDRESS $IBC_STTOKEN
Expand All @@ -312,14 +302,10 @@ setup_file() {
memo='{ "autopilot": { "receiver": "'"$(STRIDE_ADDRESS)"'", "stakeibc": { "action": "RedeemStake", "ibc_receiver": "'$HOST_RECEIVER_ADDRESS'" } } }'

# do IBC transfer
transfer_msg_prefix="$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL"
if [[ "$CHAIN_NAME" == "GAIA" ]]; then
# For GAIA (ibc-v3), pass the memo into the receiver field
$transfer_msg_prefix "$memo" ${REDEEM_AMOUNT}${IBC_STTOKEN} --from $HOST_VAL -y
else
# For all other hosts (ibc-v5), pass an address for a receiver and the memo in the --memo field
$transfer_msg_prefix $(STRIDE_ADDRESS) ${REDEEM_AMOUNT}${IBC_STTOKEN} --memo "$memo" --from $HOST_VAL -y
fi
# For all other hosts (ibc-v5), pass an address for a receiver and the memo in the --memo field
$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL \
$(STRIDE_ADDRESS) ${REDEEM_AMOUNT}${IBC_STTOKEN} --memo "$memo" --from $HOST_VAL -y $HOST_FEES

WAIT_FOR_BLOCK $STRIDE_LOGS 2

# make sure stATOM balance decreased
Expand All @@ -336,7 +322,9 @@ setup_file() {

# attempt to redeem with an invalid receiver address to invoke a failure
invalid_memo='{ "autopilot": { "receiver": "'"$(STRIDE_ADDRESS)"'", "stakeibc": { "action": "RedeemStake", "ibc_receiver": "XXX" } } }'
$transfer_msg_prefix "$invalid_memo" ${REDEEM_AMOUNT}${IBC_STTOKEN} --from $HOST_VAL -y
$HOST_MAIN_CMD tx ibc-transfer transfer transfer $HOST_TRANSFER_CHANNEL \
$(STRIDE_ADDRESS) ${REDEEM_AMOUNT}${IBC_STTOKEN} --memo "$invalid_memo" --from $HOST_VAL -y $HOST_FEES

WAIT_FOR_BLOCK $STRIDE_LOGS 10

# Confirm the stATOM balance was refunded
Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ toolchain go1.21.3
require (
cosmossdk.io/errors v1.0.1
cosmossdk.io/math v1.3.0
github.com/CosmWasm/wasmd v0.45.0
github.com/CosmWasm/wasmvm v1.5.2
github.com/CosmWasm/wasmd v0.46.0
github.com/CosmWasm/wasmvm v1.5.4
github.com/Stride-Labs/ibc-rate-limiting v1.0.0
github.com/cometbft/cometbft v0.37.4
github.com/cometbft/cometbft-db v0.8.0
Expand Down
8 changes: 4 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -212,10 +212,10 @@ github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
github.com/ChainSafe/go-schnorrkel v1.0.0 h1:3aDA67lAykLaG1y3AOjs88dMxC88PgUuHRrLeDnvGIM=
github.com/ChainSafe/go-schnorrkel v1.0.0/go.mod h1:dpzHYVxLZcp8pjlV+O+UR8K0Hp/z7vcchBSbMBEhCw4=
github.com/CosmWasm/wasmd v0.45.0 h1:9zBqrturKJwC2kVsfHvbrA++EN0PS7UTXCffCGbg6JI=
github.com/CosmWasm/wasmd v0.45.0/go.mod h1:RnSAiqbNIZu4QhO+0pd7qGZgnYAMBPGmXpzTADag944=
github.com/CosmWasm/wasmvm v1.5.2 h1:+pKB1Mz9GZVt1vadxB+EDdD1FOz3dMNjIKq/58/lrag=
github.com/CosmWasm/wasmvm v1.5.2/go.mod h1:Q0bSEtlktzh7W2hhEaifrFp1Erx11ckQZmjq8FLCyys=
github.com/CosmWasm/wasmd v0.46.0 h1:78kmiobbVE8JWBcM+ssxiFV2cS+4l9lmZQqPAQ0mA04=
github.com/CosmWasm/wasmd v0.46.0/go.mod h1:BZFz+CFGdLNGomshb3IeccFyD4R+XbnS/mXpytOUyTA=
github.com/CosmWasm/wasmvm v1.5.4 h1:Opqy65ubJ8bMsT08dn85VjRdsLJVPIAgIXif92qOMGc=
github.com/CosmWasm/wasmvm v1.5.4/go.mod h1:Q0bSEtlktzh7W2hhEaifrFp1Erx11ckQZmjq8FLCyys=
github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ=
github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0=
github.com/Microsoft/go-winio v0.6.0 h1:slsWYD/zyx7lCXoZVlvQrj0hPTM1HI4+v1sIda2yDvg=
Expand Down
8 changes: 5 additions & 3 deletions integration-tests/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@ PYTHON := $(VENV_BIN)/python

HELM_CHART=network
PLATFORM=linux/amd64
GCR_REPO = gcr.io/stride-nodes/integration-tests
GCR_REPO=gcr.io/stride-nodes/integration-tests

ADMINS_FILE=../utils/admins.go
KEYS_FILE=network/configs/keys.json

# Builds and pushes a docker image
# args: [image-file-suffix] [context] [image-name]
Expand Down Expand Up @@ -56,8 +59,7 @@ build-api:
$(call build_and_push_docker,api,api,api:latest)

build-stride:
@$(DOCKER) buildx build --platform linux/amd64 --tag core:stride ..
$(call build_and_push_docker,stride,.,chains/stride:latest)
@bash network/scripts/build.sh stride

build-cosmos:
$(call build_and_push_docker,cosmos,.,chains/cosmoshub:v18.1.0)
Expand Down
1 change: 1 addition & 0 deletions integration-tests/network/configs/keys.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

"admin": {
"name": "admin",
"address": "stride1u20df3trc2c2zdhm8qvh2hdjx9ewh00sv6eyy8",
"mnemonic": "tone cause tribe this switch near host damage idle fragile antique tail soda alien depth write wool they rapid unfold body scan pledge soft"
},
"faucet": {
Expand Down
54 changes: 54 additions & 0 deletions integration-tests/network/scripts/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
#!/bin/bash
set -eu

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
STRIDE_HOME=$SCRIPT_DIR/../../..

CHAIN=$1

PLATFORM=linux/amd64
GCR_REPO=gcr.io/stride-nodes/integration-tests
ADMINS_FILE=${STRIDE_HOME}/utils/admins.go
KEYS_FILE=${STRIDE_HOME}/integration-tests/network/configs/keys.json
DOCKERFILES=${STRIDE_HOME}/integration-tests/dockerfiles

# Builds and pushes a docker image to GCR
build_and_push_docker() {
dockerfile_suffix=$1
context=$2
image_name=$3

local_tag=stride-tests:$dockerfile_suffix
global_tag=$GCR_REPO/${image_name}

echo "Building docker image: $dockerfile_suffix"
docker buildx build --platform $PLATFORM --tag $local_tag -f ${DOCKERFILES}/Dockerfile.$dockerfile_suffix $context
docker tag $local_tag $global_tag

echo "Pushing image to GCR: $global_tag"
docker push $global_tag
}

main() {
# For stride, we have to update the admin address
if [[ "$CHAIN" == "stride" ]]; then
# Trap SIGINT (Control + C) to cleanup admins file
trap 'echo "Interrupt received, cleaning up..."; git checkout -- $ADMINS_FILE && rm -f ${ADMINS_FILE}-E; exit' INT

# Update the admin address
admin_address=$(jq -r '.admin.address' $KEYS_FILE)
sed -i -E "s|stride1k8c2m5cn322akk5wy8lpt87dd2f4yh9azg7jlh|$admin_address|g" $ADMINS_FILE

# First build the main dockerfile in the repo root, then build the integration test specific file
docker buildx build --platform linux/amd64 --tag core:stride ..
build_and_push_docker stride . chains/stride:latest

# Cleanup the admins file
git checkout -- $ADMINS_FILE && rm -f ${ADMINS_FILE}-E
else
echo "ERROR: Chain not supported"
exit 1
fi
}

main
1 change: 1 addition & 0 deletions integration-tests/network/scripts/config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ DEPOSIT_PERIOD="30s"
VOTING_PERIOD="30s"
EXPEDITED_VOTING_PERIOD="29s"
UNBONDING_TIME="240s"
AIRDROP_PERIOD_SECONDS=86400

STRIDE_DAY_EPOCH_DURATION="140s"
STRIDE_EPOCH_EPOCH_DURATION="35s"
2 changes: 2 additions & 0 deletions integration-tests/network/scripts/init-chain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,8 @@ update_stride_genesis() {

$BINARY add-consumer-section --validator-public-keys $validator_public_keys
jq_inplace '.app_state.ccvconsumer.params.unbonding_period |= "'$UNBONDING_TIME'"' $genesis_json

jq_inplace '.app_state.airdrop.params.period_length_seconds |= "'${AIRDROP_PERIOD_LENGTH}'"' $genesis_json
}

# Genesis updates specific to non-stride chains
Expand Down
Loading

0 comments on commit 8185fe5

Please sign in to comment.