Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable proto JSON generally and remove HybridCodec #6859

Merged
merged 37 commits into from
Aug 13, 2020
Merged
Changes from 1 commit
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
e20e717
Remove HybridCodec
aaronc Jul 27, 2020
6788a6c
Merge branch 'master' into aaronc/6837-final
jgimeno Jul 29, 2020
46bf0ee
Merge branch 'master' of https://github.com/cosmos/cosmos-sdk into aa…
aaronc Jul 30, 2020
3732302
Merge branch 'master' of https://github.com/cosmos/cosmos-sdk into aa…
aaronc Aug 7, 2020
6bd19c4
WIP on fixing proto JSON issues
aaronc Aug 7, 2020
4b41af5
WIP on fixing proto JSON issues
aaronc Aug 7, 2020
675d9f7
WIP on fixing proto JSON issues
aaronc Aug 7, 2020
ce3ae55
WIP on fixing proto JSON issues
aaronc Aug 7, 2020
c208575
WIP on fixing proto JSON issues
aaronc Aug 7, 2020
4c067a2
Merge branch 'master' of https://github.com/cosmos/cosmos-sdk into aa…
aaronc Aug 10, 2020
81beade
Test fixes
aaronc Aug 10, 2020
0acdd2a
Merge branch 'master' of https://github.com/cosmos/cosmos-sdk into aa…
aaronc Aug 11, 2020
63ebec3
Delete hybrid_codec.go
aaronc Aug 11, 2020
48adb63
Fixes
aaronc Aug 11, 2020
8cc6084
Fixes
aaronc Aug 11, 2020
06b012b
Fixes
aaronc Aug 11, 2020
42bd0a8
Merge branch 'master' of https://github.com/cosmos/cosmos-sdk into aa…
aaronc Aug 11, 2020
722da0b
Test fixes
aaronc Aug 11, 2020
053b77f
Test fixes
aaronc Aug 11, 2020
f651177
Test fixes
aaronc Aug 11, 2020
eed9418
Lint
aaronc Aug 11, 2020
7b62fad
Sim fixes
aaronc Aug 11, 2020
9d88118
Sim fixes
aaronc Aug 11, 2020
40f8816
Revert
aaronc Aug 11, 2020
7dbeffd
Remove vesting account JSON tests
aaronc Aug 11, 2020
fab24c6
Update CHANGELOG.md
aaronc Aug 11, 2020
11d5c04
Lint
aaronc Aug 11, 2020
9e8a745
Sim fixes
aaronc Aug 11, 2020
b52ab51
Sim fixes
aaronc Aug 11, 2020
d0c1263
Docs
aaronc Aug 11, 2020
66ca469
Merge branch 'master' of https://github.com/cosmos/cosmos-sdk into aa…
aaronc Aug 12, 2020
e98c8d2
Migrate more amino usages
aaronc Aug 12, 2020
55d681d
Merge branch 'master' into aaronc/6837-final
aaronc Aug 12, 2020
7a91e69
Remove custom VoteOption String() and json marshaling
aaronc Aug 12, 2020
0d929fa
Merge branch 'master' into aaronc/6837-final
alexanderbez Aug 12, 2020
2b0f52b
Fix tests
aaronc Aug 12, 2020
d6643ba
Add comments, update CHANGELOG.md
aaronc Aug 12, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Sim fixes
aaronc committed Aug 11, 2020
commit 9e8a745d7d21b870e419978a84210bf9e1e6f455
16 changes: 8 additions & 8 deletions simapp/sim_test.go
Original file line number Diff line number Diff line change
@@ -104,8 +104,8 @@ func TestAppImportExport(t *testing.T) {

// Run randomized simulation
_, simParams, simErr := simulation.SimulateFromSeed(
t, os.Stdout, app.BaseApp, AppStateFn(app.LegacyAmino(), app.SimulationManager()),
SimulationOperations(app, app.LegacyAmino(), config),
t, os.Stdout, app.BaseApp, AppStateFn(app.AppCodec(), app.SimulationManager()),
SimulationOperations(app, app.AppCodec(), config),
app.ModuleAccountAddrs(), config,
)

@@ -137,12 +137,12 @@ func TestAppImportExport(t *testing.T) {
require.Equal(t, "SimApp", newApp.Name())

var genesisState GenesisState
err = app.LegacyAmino().UnmarshalJSON(appState, &genesisState)
err = json.Unmarshal(appState, &genesisState)
require.NoError(t, err)

ctxA := app.NewContext(true, abci.Header{Height: app.LastBlockHeight()})
ctxB := newApp.NewContext(true, abci.Header{Height: app.LastBlockHeight()})
newApp.mm.InitGenesis(ctxB, app.LegacyAmino(), genesisState)
newApp.mm.InitGenesis(ctxB, app.AppCodec(), genesisState)
newApp.StoreConsensusParams(ctxB, consensusParams)

fmt.Printf("comparing stores...\n")
@@ -195,8 +195,8 @@ func TestAppSimulationAfterImport(t *testing.T) {

// Run randomized simulation
stopEarly, simParams, simErr := simulation.SimulateFromSeed(
t, os.Stdout, app.BaseApp, AppStateFn(app.LegacyAmino(), app.SimulationManager()),
SimulationOperations(app, app.LegacyAmino(), config),
t, os.Stdout, app.BaseApp, AppStateFn(app.AppCodec(), app.SimulationManager()),
SimulationOperations(app, app.AppCodec(), config),
app.ModuleAccountAddrs(), config,
)

@@ -237,8 +237,8 @@ func TestAppSimulationAfterImport(t *testing.T) {
})

_, _, err = simulation.SimulateFromSeed(
t, os.Stdout, newApp.BaseApp, AppStateFn(app.LegacyAmino(), app.SimulationManager()),
SimulationOperations(newApp, newApp.LegacyAmino(), config),
t, os.Stdout, newApp.BaseApp, AppStateFn(app.AppCodec(), app.SimulationManager()),
SimulationOperations(newApp, newApp.AppCodec(), config),
newApp.ModuleAccountAddrs(), config,
)
require.NoError(t, err)
6 changes: 3 additions & 3 deletions simapp/utils.go
Original file line number Diff line number Diff line change
@@ -20,9 +20,9 @@ import (
// the simulation tests. If `FlagEnabledValue` is false it skips the current test.
// Returns error on an invalid db intantiation or temp dir creation.
func SetupSimulation(dirPrefix, dbName string) (simtypes.Config, dbm.DB, string, log.Logger, bool, error) {
if !FlagEnabledValue {
return simtypes.Config{}, nil, "", nil, true, nil
}
//if !FlagEnabledValue {
// return simtypes.Config{}, nil, "", nil, true, nil
//}

config := NewConfigFromFlags()
config.ChainID = helpers.SimAppChainID