Skip to content

Commit 3036618

Browse files
fix: unwire spot module for main branch (#1831)
* feat: rest in peace * fix: fix e2e wasm test * fix: fix justfile and deplyo-wasm * fix: update localnet * feat: rest in peace * fix(localnet.sh): change order of operations in genesis config * fix(localnet.sh): change order of operations in genesis config * rm unused file --------- Co-authored-by: Unique-Divine <[email protected]> Co-authored-by: Unique Divine <[email protected]>
1 parent da22964 commit 3036618

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+3
-28194
lines changed

app/keepers.go

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -111,10 +111,6 @@ import (
111111
oraclekeeper "github.com/NibiruChain/nibiru/x/oracle/keeper"
112112
oracletypes "github.com/NibiruChain/nibiru/x/oracle/types"
113113

114-
"github.com/NibiruChain/nibiru/x/spot"
115-
spotkeeper "github.com/NibiruChain/nibiru/x/spot/keeper"
116-
spottypes "github.com/NibiruChain/nibiru/x/spot/types"
117-
118114
"github.com/NibiruChain/nibiru/x/sudo"
119115
"github.com/NibiruChain/nibiru/x/sudo/keeper"
120116
sudotypes "github.com/NibiruChain/nibiru/x/sudo/types"
@@ -169,7 +165,6 @@ type AppKeepers struct {
169165
// Nibiru keepers
170166
// ---------------
171167
EpochsKeeper epochskeeper.Keeper
172-
SpotKeeper spotkeeper.Keeper
173168
OracleKeeper oraclekeeper.Keeper
174169
InflationKeeper inflationkeeper.Keeper
175170
SudoKeeper keeper.Keeper
@@ -208,7 +203,6 @@ func initStoreKeys() (
208203
ibcexported.StoreKey,
209204

210205
// nibiru x/ keys
211-
spottypes.StoreKey,
212206
oracletypes.StoreKey,
213207
epochstypes.StoreKey,
214208
inflationtypes.StoreKey,
@@ -348,10 +342,6 @@ func (app *NibiruApp) InitKeepers(
348342

349343
// ---------------------------------- Nibiru Chain x/ keepers
350344

351-
app.SpotKeeper = spotkeeper.NewKeeper(
352-
appCodec, keys[spottypes.StoreKey], app.GetSubspace(spottypes.ModuleName),
353-
app.AccountKeeper, app.BankKeeper, app.DistrKeeper)
354-
355345
app.SudoKeeper = keeper.NewKeeper(
356346
appCodec, keys[sudotypes.StoreKey],
357347
)
@@ -578,7 +568,6 @@ func (app *NibiruApp) initAppModules(
578568
authzmodule.NewAppModule(appCodec, app.authzKeeper, app.AccountKeeper, app.BankKeeper, app.interfaceRegistry),
579569

580570
// Nibiru modules
581-
spot.NewAppModule(appCodec, app.SpotKeeper, app.AccountKeeper, app.BankKeeper),
582571
oracle.NewAppModule(appCodec, app.OracleKeeper, app.AccountKeeper, app.BankKeeper),
583572
epochs.NewAppModule(appCodec, app.EpochsKeeper),
584573
inflation.NewAppModule(app.InflationKeeper, app.AccountKeeper, *app.stakingKeeper),
@@ -649,7 +638,6 @@ func orderedModuleNames() []string {
649638
// --------------------------------------------------------------------
650639
// Native x/ Modules
651640
epochstypes.ModuleName,
652-
spottypes.ModuleName,
653641
oracletypes.ModuleName,
654642
inflationtypes.ModuleName,
655643
sudotypes.ModuleName,
@@ -762,7 +750,6 @@ func ModuleBasicManager() module.BasicManager {
762750
ibctransfer.AppModuleBasic{},
763751
ibctm.AppModuleBasic{},
764752
// native x/
765-
spot.AppModuleBasic{},
766753
oracle.AppModuleBasic{},
767754
epochs.AppModuleBasic{},
768755
inflation.AppModuleBasic{},
@@ -783,7 +770,6 @@ func ModuleAccPerms() map[string][]string {
783770
stakingtypes.BondedPoolName: {authtypes.Burner, authtypes.Staking},
784771
stakingtypes.NotBondedPoolName: {authtypes.Burner, authtypes.Staking},
785772
govtypes.ModuleName: {authtypes.Burner},
786-
spottypes.ModuleName: {authtypes.Minter, authtypes.Burner},
787773
oracletypes.ModuleName: {},
788774
ibctransfertypes.ModuleName: {authtypes.Minter, authtypes.Burner},
789775
ibcfeetypes.ModuleName: {},
@@ -810,7 +796,6 @@ func initParamsKeeper(
810796
paramsKeeper.Subspace(govtypes.ModuleName)
811797
paramsKeeper.Subspace(crisistypes.ModuleName)
812798
// Nibiru core params keepers | x/
813-
paramsKeeper.Subspace(spottypes.ModuleName)
814799
paramsKeeper.Subspace(epochstypes.ModuleName)
815800
paramsKeeper.Subspace(inflationtypes.ModuleName)
816801
// ibc params keepers

contrib/scripts/localnet.sh

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ console_log_text_color() {
2424
}
2525

2626
if [ console_log_text_color ]; then
27-
echo "successfully toggled console coloring"
27+
echo "succesfully toggled console coloring"
2828
else
2929
# For Ubuntu and Debian. MacOS has tput by default.
3030
apt-get install libncurses5-dbg -y
@@ -58,8 +58,6 @@ echo_info "Parsing flags for the script..."
5858
# behavior of the script is to run make install if the flag --no-build is not present.
5959
FLAG_NO_BUILD=false
6060

61-
# $FLAG_SPOT: Feature flag for x/spot. Enabled with `--features spot`.
62-
FLAG_SPOT=false
6361

6462
build_from_source() {
6563
echo_info "Building from source..."
@@ -97,14 +95,14 @@ while [[ $# -gt 0 ]]; do
9795
esac
9896
done
9997

98+
10099
# Check if FLAG_NO_BUILD was set to true
101100
if ! $FLAG_NO_BUILD; then
102101
build_from_source
103102
fi
104103

105104
echo_info "Features flags:"
106105
echo "FLAG_NO_BUILD: $FLAG_NO_BUILD"
107-
echo "FLAG_SPOT: $FLAG_SPOT"
108106

109107
SEDOPTION=""
110108
if [[ "$OSTYPE" == "darwin"* ]]; then
@@ -188,10 +186,6 @@ add_genesis_param() {
188186

189187
echo_info "Configuring genesis params"
190188

191-
# if $FLAG_SPOT; then
192-
# # Perform any actions specific to the x/spot feature
193-
# fi
194-
195189
# set validator as sudoer
196190
add_genesis_param '.app_state.sudo.sudoers.root = "'"$val_address"'"'
197191

@@ -203,8 +197,6 @@ add_genesis_param '.app_state.oracle.exchange_rates[0].exchange_rate = "'"$price
203197
add_genesis_param '.app_state.oracle.exchange_rates[1].pair = "ueth:uuusd"'
204198
add_genesis_param '.app_state.oracle.exchange_rates[1].exchange_rate = "'"$price_eth"'"'
205199

206-
add_genesis_param '.app_state.inflation.params.inflation_enabled = false'
207-
208200
# ------------------------------------------------------------------------
209201
# Gentx
210202
# ------------------------------------------------------------------------

contrib/scripts/testing/stableswap_model.py

Lines changed: 0 additions & 238 deletions
This file was deleted.

justfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ lint:
3939

4040
golangci-lint run --allow-parallel-runners --fix
4141

42-
# Runs a Nibiru local network. Ex: "just localnet --features spot"
42+
# Runs a Nibiru local network. Ex: "just localnet", "just localnet --features featureA"
4343
localnet *PASS_FLAGS:
4444
make localnet FLAGS="{{PASS_FLAGS}}"
4545

0 commit comments

Comments
 (0)