Skip to content

Commit

Permalink
added rebate simulated trade script (#1156)
Browse files Browse the repository at this point in the history
  • Loading branch information
sampocs authored Mar 21, 2024
1 parent 35ab2fb commit 1882c33
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
4 changes: 2 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### On-Chain changes
1. v20 upgrade handler scaffolding ([#1148](https://github.com/Stride-Labs/stride/pull/1148))
2. Upgraded ICS to 4.0 ([#1153](https://github.com/Stride-Labs/stride/pull/1153))
2. Upgraded ICS to 4.0 ([#1153](https://github.com/Stride-Labs/stride/pull/1153),[#1157](https://github.com/Stride-Labs/stride/pull/1157))
3. add community pool rebate feature ([#1135](https://github.com/Stride-Labs/stride/pull/1135))
4. v20 Import Paths ([#1155](https://github.com/Stride-Labs/stride/pull/1155))

### Off-Chain changes
1. fixing init_chain script to not clobber new params ([#1139](https://github.com/Stride-Labs/stride/pull/1139))
2. added wasm to cosmovisor upgrade image ([#1158](https://github.com/Stride-Labs/stride/pull/1158))

3. added dockernet scripts to test rebate ([#1156](https://github.com/Stride-Labs/stride/pull/1156))

## [v19.0.0](https://github.com/Stride-Labs/stride/releases/tag/v19.0.0) - 2024-03-07

Expand Down
12 changes: 12 additions & 0 deletions dockernet/scripts/community-pool-staking/trade_simulated.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash
set -eu
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
source ${SCRIPT_DIR}/../../config.sh

TRADE_AMOUNT=997500

# Simulates a trade by sending the native token to the trade account
# We'll send the amount that should have been sent from the ICA, which has the rebate excluded
trade_account=$($STRIDE_MAIN_CMD q stakeibc list-trade-routes | grep trade_account -A 3 | grep address | awk '{print $2}')
host_denom_on_trade=$($STRIDE_MAIN_CMD q stakeibc list-trade-routes | grep host_denom_on_trade | awk '{print $2}')
$OSMO_MAIN_CMD tx bank send ${OSMO_VAL_PREFIX}1 $trade_account ${TRADE_AMOUNT}${host_denom_on_trade} --from ${OSMO_VAL_PREFIX}1 -y

0 comments on commit 1882c33

Please sign in to comment.