Skip to content

Commit

Permalink
remove ignite cli from options (#234)
Browse files Browse the repository at this point in the history
  • Loading branch information
Reecepbcups authored Oct 11, 2024
1 parent ecd8666 commit 03b4b0d
Show file tree
Hide file tree
Showing 13 changed files with 9 additions and 55 deletions.
1 change: 0 additions & 1 deletion cmd/spawn/new_chain.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ var (
{ID: "cosmwasm", IsSelected: false, Details: "Cosmos smart contracts"},
{ID: "wasm-light-client", IsSelected: false, Details: "08 Wasm Light Client"},
{ID: "optimistic-execution", IsSelected: false, Details: "Pre-process blocks ahead of consensus request"},
{ID: "ignite-cli", IsSelected: false, Details: "Ignite-CLI Support"},
{ID: "block-explorer", IsSelected: true, Details: "Ping Pub Explorer"},
}...)

Expand Down
2 changes: 1 addition & 1 deletion cmd/spawn/new_chain_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ func TestDisabledGeneration(t *testing.T) {
},
{
Name: "stdmix1",
Disabled: []string{spawn.Ignite, spawn.TokenFactory},
Disabled: []string{spawn.TokenFactory},
NotContainAny: []string{"TokenFactoryKeeper"},
},
{
Expand Down
1 change: 0 additions & 1 deletion docs/versioned_docs/version-v0.50.x/00-meet-spawn.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ Feature Selector (( enter to toggle ))
cosmwasm
wasm-light-client
✔ optimistic-execution
ignite-cli
✔ block-explorer
tokenfactory: Native token minting, sending, and burning on the chain
```
Expand Down
9 changes: 3 additions & 6 deletions scripts/matrix_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
"cosmwasm",
"wasm-light-client",
"optimistic-execution",
"ignite-cli",
]

POS = "proof-of-stake"
Expand Down Expand Up @@ -47,7 +46,7 @@ def main():
CmdCreator(
"spawndefaultfeatures",
POA,
"ibc-ratelimit,cosmwasm,wasm-light-client,ignite-cli".split(","),
"ibc-ratelimit,cosmwasm,wasm-light-client".split(","),
"cosmos",
"appd",
"utoken",
Expand Down Expand Up @@ -83,7 +82,7 @@ def main():
CmdCreator(
"randmixone",
POS,
"wasmlc,ignite".split(","),
"wasmlc".split(","),
random_string(5, True),
f"{random_string(6, True)}",
f"u{random_string(5, True)}",
Expand Down Expand Up @@ -116,9 +115,7 @@ def main():
CmdCreator(
"randmixfour",
POA,
"ignite,ignite,ignite,ignite,ignite,ignite,ignite,ignite,ignite,ignite,wasmlc,packetforward,tokenfactory".split(
","
),
"wasmlc,packetforward,tokenfactory".split(","),
random_string(5, True),
f"{random_string(6, True)}",
f"u{random_string(5, True)}",
Expand Down
13 changes: 0 additions & 13 deletions simapp/app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ import (
ibctm "github.com/cosmos/ibc-go/v8/modules/light-clients/07-tendermint"
"github.com/spf13/cast"

// this line is used by starport scaffolding # ibc/app/import

autocliv1 "cosmossdk.io/api/cosmos/autocli/v1"
reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1"
"cosmossdk.io/client/v2/autocli"
Expand Down Expand Up @@ -171,7 +169,6 @@ import (
//distr "github.com/cosmos/cosmos-sdk/x/distribution" // ?spawntag:ics
//"github.com/cosmos/cosmos-sdk/x/gov" // ?spawntag:ics
//"github.com/cosmos/cosmos-sdk/x/staking" // ?spawntag:ics
// this line is used by starport scaffolding # stargate/app/moduleImport
)

const (
Expand Down Expand Up @@ -229,7 +226,6 @@ var maccPerms = map[string][]string{
tokenfactorytypes.ModuleName: {authtypes.Minter, authtypes.Burner},
ccvconsumertypes.ConsumerRedistributeName: nil,
ccvconsumertypes.ConsumerToSendToProviderName: nil,
// this line is used by starport scaffolding # stargate/app/maccPerms
}

var (
Expand Down Expand Up @@ -285,8 +281,6 @@ type ChainApp struct {
WasmClientKeeper wasmlckeeper.Keeper
RatelimitKeeper ratelimitkeeper.Keeper

// this line is used by starport scaffolding # stargate/app/keeperDeclaration

ScopedIBCKeeper capabilitykeeper.ScopedKeeper
ScopedICAHostKeeper capabilitykeeper.ScopedKeeper
ScopedICAControllerKeeper capabilitykeeper.ScopedKeeper
Expand Down Expand Up @@ -922,8 +916,6 @@ func NewChainApp(
ibcRouter.AddRoute(icahosttypes.SubModuleName, icaHostStack)
app.IBCKeeper.SetRouter(ibcRouter)

// this line is used by starport scaffolding # ibc/app/module

// --- Module Options ---

// NOTE: we may consider parsing `appOpts` inside module constructors. For the moment
Expand Down Expand Up @@ -994,15 +986,13 @@ func NewChainApp(
app.ModuleManager,
map[string]module.AppModuleBasic{
genutiltypes.ModuleName: genutil.NewAppModuleBasic(genutiltypes.DefaultMessageValidator),
// this line is used by starport scaffolding # stargate/appConfig/moduleBasic
})
app.BasicModuleManager.RegisterLegacyAminoCodec(legacyAmino)
app.BasicModuleManager.RegisterInterfaces(interfaceRegistry)

// NOTE: upgrade module is required to be prioritized
app.ModuleManager.SetOrderPreBlockers(
upgradetypes.ModuleName,
// this line is used by starport scaffolding # stargate/app/preBlockers
)
// During begin block slashing happens after distr.BeginBlocker so that
// there is nothing left over in the validator fee pool, so as to keep the
Expand Down Expand Up @@ -1030,7 +1020,6 @@ func NewChainApp(
wasmlctypes.ModuleName,
ratelimittypes.ModuleName,
ccvconsumertypes.ModuleName,
// this line is used by starport scaffolding # stargate/app/beginBlockers
)

app.ModuleManager.SetOrderEndBlockers(
Expand All @@ -1053,7 +1042,6 @@ func NewChainApp(
wasmlctypes.ModuleName,
ratelimittypes.ModuleName,
ccvconsumertypes.ModuleName,
// this line is used by starport scaffolding # stargate/app/endBlockers
)

// NOTE: The genutils module must occur after staking so that pools are
Expand Down Expand Up @@ -1098,7 +1086,6 @@ func NewChainApp(
wasmlctypes.ModuleName,
ratelimittypes.ModuleName,
ccvconsumertypes.ModuleName,
// this line is used by starport scaffolding # stargate/app/initGenesis
}
app.ModuleManager.SetOrderInitGenesis(genesisModuleOrder...)
app.ModuleManager.SetOrderExportGenesis(genesisModuleOrder...)
Expand Down
3 changes: 0 additions & 3 deletions simapp/x/example/keeper/genesis_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,11 @@ func TestGenesis(t *testing.T) {

genesisState := &types.GenesisState{
Params: types.DefaultParams(),

// this line is used by starport scaffolding # genesis/test/state
}

f.k.InitGenesis(f.ctx, genesisState)

got := f.k.ExportGenesis(f.ctx)
require.NotNil(t, got)

// this line is used by starport scaffolding # genesis/test/assert
}
4 changes: 1 addition & 3 deletions simapp/x/example/keeper/keeper.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ func (k Keeper) Logger() log.Logger {

// InitGenesis initializes the module's state from a genesis state.
func (k *Keeper) InitGenesis(ctx context.Context, data *types.GenesisState) error {
// this line is used by starport scaffolding # genesis/module/init

if err := data.Params.Validate(); err != nil {
return err
}
Expand All @@ -96,8 +96,6 @@ func (k *Keeper) ExportGenesis(ctx context.Context) *types.GenesisState {
panic(err)
}

// this line is used by starport scaffolding # genesis/module/export

return &types.GenesisState{
Params: params,
}
Expand Down
3 changes: 0 additions & 3 deletions simapp/x/example/module.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,11 @@ import (

"github.com/rollchains/spawn/simapp/x/example/keeper"
"github.com/rollchains/spawn/simapp/x/example/types"
// this line is used by starport scaffolding # 1
)

const (
// ConsensusVersion defines the current x/example module consensus version.
ConsensusVersion = 1

// this line is used by starport scaffolding # simapp/module/const
)

var (
Expand Down
2 changes: 0 additions & 2 deletions simapp/x/example/types/codec.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import (
cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec"
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/msgservice"
// this line is used by starport scaffolding # 1
)

var (
Expand All @@ -26,7 +25,6 @@ func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) {
}

func RegisterInterfaces(registry types.InterfaceRegistry) {
// this line is used by starport scaffolding # 3

registry.RegisterImplementations(
(*sdk.Msg)(nil),
Expand Down
5 changes: 1 addition & 4 deletions simapp/x/example/types/genesis.go
Original file line number Diff line number Diff line change
@@ -1,22 +1,19 @@
package types

// this line is used by starport scaffolding # genesis/types/import

// DefaultIndex is the default global index
const DefaultIndex uint64 = 1

// DefaultGenesis returns the default genesis state
func DefaultGenesis() *GenesisState {
return &GenesisState{
// this line is used by starport scaffolding # genesis/types/default

Params: DefaultParams(),
}
}

// Validate performs basic genesis state validation returning an error upon any
// failure.
func (gs GenesisState) Validate() error {
// this line is used by starport scaffolding # genesis/types/validate

return gs.Params.Validate()
}
8 changes: 2 additions & 6 deletions simapp/x/example/types/genesis_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,9 @@ func TestGenesisState_Validate(t *testing.T) {
},
{
desc: "valid genesis state",
genState: &types.GenesisState{

// this line is used by starport scaffolding # types/genesis/validField
},
valid: true,
genState: &types.GenesisState{},
valid: true,
},
// this line is used by starport scaffolding # types/genesis/testcase
}
for _, tc := range tests {
t.Run(tc.desc, func(t *testing.T) {
Expand Down
2 changes: 0 additions & 2 deletions simapp/x/ibcmodule/types/codec.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import (
cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec"
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/msgservice"
// this line is used by starport scaffolding # 1
)

var (
Expand All @@ -26,7 +25,6 @@ func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) {
}

func RegisterInterfaces(registry types.InterfaceRegistry) {
// this line is used by starport scaffolding # 3

registry.RegisterImplementations(
(*sdk.Msg)(nil),
Expand Down
11 changes: 1 addition & 10 deletions spawn/remove_features.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ var (
WasmLC = "wasmlc"
PacketForward = "packetforward"
IBCRateLimit = "ibc-ratelimit"
Ignite = "ignite"
InterchainSecurity = "ics"
OptimisticExecution = "optimistic-execution"
BlockExplorer = "block-explorer"
Expand All @@ -30,7 +29,7 @@ var (
// used for fuzz testing
var AllFeatures = []string{
TokenFactory, POA, CosmWasm, WasmLC,
PacketForward, IBCRateLimit, Ignite, InterchainSecurity, POS,
PacketForward, IBCRateLimit, InterchainSecurity, POS,
}

// Given a string, return the reduced name for the module
Expand All @@ -50,8 +49,6 @@ func AliasName(name string) string {
return WasmLC
case PacketForward, "ibc-packetforward", "pfm":
return PacketForward
case Ignite, "ignite-cli":
return Ignite
case OptimisticExecution, "optimisticexecution", "optimistic-exec":
return OptimisticExecution
case IBCRateLimit, "ibc-rate-limit", "ratelimit":
Expand Down Expand Up @@ -91,8 +88,6 @@ func (fc *FileContent) RemoveDisabledFeatures(cfg *NewChainConfig) {
case IBCRateLimit:
fc.RemoveIBCRateLimit()
// other
case Ignite:
fc.RemoveIgniteCLI()
case OptimisticExecution:
fc.RemoveOptimisticExecution()
case BlockExplorer:
Expand Down Expand Up @@ -234,10 +229,6 @@ func (fc *FileContent) RemoveIBCRateLimit() {
fc.DeleteFile(path.Join("interchaintest", "ibc_rate_limit_test.go"))
}

func (fc *FileContent) RemoveIgniteCLI() {
fc.RemoveLineWithAnyMatch("starport scaffolding")
}

func (fc *FileContent) RemoveOptimisticExecution() {
fc.RemoveTaggedLines(OptimisticExecution, true)
}
Expand Down

0 comments on commit 03b4b0d

Please sign in to comment.