Commit Graph

213 Commits

Author SHA1 Message Date
0g-wh
78caabebe1 fix mint denom in upgrades.go 2024-08-09 14:11:35 +08:00
MiniFrenchBread
f4408080e6
fix: designers; test: designers, precompile (#59)
* test: dasigners test

* test: genesis

* fix: abci; test: abci

* test: types

* test: keeper test

* test: util

* test: dasigners precompile

* chore: remove log
2024-08-09 13:34:37 +08:00
0g-wh
ed5646b71a add ibcwasmtypes to upgrades.go 2024-08-04 19:39:00 +08:00
0g-wh
bd3d947e9b clean code 2024-08-04 15:25:53 +08:00
aeryz
a8c86f7f8b feat: add 08-wasm module
Signed-off-by: aeryz <abdullaheryz@protonmail.com>
2024-08-04 15:23:35 +08:00
0g-wh
04dfd2a2e9 fix review issues 2024-08-04 13:56:43 +08:00
0g-wh
932664efac prepare upgrade
Some checks are pending
Continuous Integration (Commit) / lint (push) Waiting to run
2024-08-03 15:05:14 +08:00
0g-wh
c949c06fce rebase to kava cosmos 0.47 upgrade
rename

rename

tidy

clean code
2024-08-03 15:05:14 +08:00
0xsatoshi
4ab0d3ee27 enable vesting msgs 2024-08-03 15:05:14 +08:00
0xsatoshi
8d761147a2 fix 2024-08-03 15:05:14 +08:00
0xsatoshi
4917eb5976 fix 2024-08-03 15:05:14 +08:00
Solovyov1796
986172d3a7 rename denoms 2024-08-03 15:05:13 +08:00
Solovyov1796
4fabd4d011 fix unit test 2024-08-03 15:05:03 +08:00
Solovyov1796
c7ed82b4f4 remove das module 2024-08-03 15:04:55 +08:00
MiniFrenchBread
b53783447b feat: precompile 2024-08-03 15:04:55 +08:00
Solovyov1796
47cee39c64 fix unit test 2024-08-03 15:04:53 +08:00
0xsatoshi
3da66a87e6 fix 2024-08-03 15:04:48 +08:00
Solovyov1796
34a76200f0 fix unit test for x 2024-08-03 15:04:48 +08:00
Solovyov1796
89d3829646 add 0g code 2024-08-03 15:04:48 +08:00
Solovyov1796
ffad9dbdd5 rename kava 2024-08-03 15:04:46 +08:00
Solovyov1796
454733f55b remove useless modules 2024-08-03 15:04:32 +08:00
Solovyov1796
14e1e3a7d4 rename go mod path 2024-08-03 15:03:23 +08:00
Nick DeLuca
c9d900be2c
Set the CDP Block Interval to 100 during v0.26.x upgrade (#1865)
* set CDP block interval to 100 to only run interest synchronization
for risky cdps every 100 blocks instead of every block

* refactor and use constant for setting to improve clarity; update
block interval to 50 instead of 100.  This will decrease risk by
running around every 6 minutes instead of 12 mintues for current
mainnet block times.
2024-03-29 11:05:26 -07:00
Nick DeLuca
8f93ca2048
Use IAVL 0.20.x for v0.26.x release, update deps (#1862)
* revert back to iavl v1 to avoid hash changes on new modules like
we are seeing on the v0.24.x to v0.25.x upgrade block.  Also, add
replace statements for exp and rapid to match upstream cosmos-sdk

* fix sharding prune store logging and error return.

* add comment to clarify WithKeyTable usage
2024-03-28 14:38:07 -07:00
Draco
6b41ed84b8
Add packet forward store to upgrade (#1843) 2024-03-08 16:34:31 -05:00
Draco
17691e95a8
Merge branch 'master' into release/v0.26.x 2024-03-08 09:10:32 -05:00
Draco
5c0f27b952
Add ibc packet forward middleware for ibc transfer (#1839)
* Add ibc packet forward middleware for ibc transfer

* Update changelog for ibc packet forwarding
2024-03-07 16:47:46 -05:00
Levi Schoen
2bc0c62570
register solomachine module for v6 to v7 ibc-go migration (#1831) 2024-02-16 12:49:58 -05:00
Levi Schoen
58d04e2996 register solomachine module for v6 to v7 ibc-go migration (#1830) 2024-02-15 15:24:55 -08:00
Draco
ad387e6a42
Add upgrade handler for Kava v0.26.0 (#1827)
* Add upgrade handler for Kava v0.26.0

* Update tests e2e to run upgrade tests
2024-02-13 13:27:27 -05:00
Draco
614d4e40fe
Update cosmos-sdk to v0.47.7 (#1811)
* Update cometbft, cosmos, ethermint, and ibc-go

* Replace github.com/tendermint/tendermint by github.com/cometbft/cometbft

* Replace github.com/tendermint/tm-db by github.com/cometbft/cometbft-db

* Replace gogo/protobuf with cosmos/gogoproto & simapp replacement

* Replace cosmos-sdk/simapp/helpers with cosmos-sdk/testutil/sims

* Remove no longer used simulations

* Replace ibchost with ibcexported
See https://github.com/cosmos/ibc-go/blob/v7.2.2/docs/migrations/v6-to-v7.md#ibc-module-constants

* Add new consensus params keeper

* Add consensus keeper to blockers

* Fix keeper and module issues in app.go

* Add IsSendEnabledCoins and update SetParams interface changes

* Fix protobuf build for cosmos 47 (#1800)

* fix cp errors by using -f; fix lint by only linting our proto dir;
and use proofs.proto directly from ics23 for ibc-go v7

* run proto-all; commit updated third party deps and swagger changes

* regenerate proto files

* use correct gocosmos build plugin for buf

* re-gen all protobuf files to update paths for new gocosmos plugin

* update protoc and buf to latest versions

* fix staking keeper issues in app.go

* update tally handler for gov changes

* chain id fix and flag fixes

* update deps for cometbft 47.7 upgrade

* remove all module legacy queriers

* update stakingKeeper to pointer

* Replace ModuleCdc from govv1beta1 to govcodec

* remove simulations

* abci.LastCommitInfo → abci.CommitInfo

* Remove unused code in keys.go

* simapp.MakeTestEncodingConfig -> moduletestutil.MakeTestEncodingConfi

* Fix chain id issues in tests

* Fix remaining unit test issues

* Update changelog for upgrade

* Fix e2e tests using updated kvtool

* Update protonet to v47 compatible genesis

* Bump cometbft-db to v0.9.1-kava.1

* Update kvtool

* Remove extra changelog

* Fix merged rocksdb issues

* go mod cleanup

* Bump cometbft-db to v9 and go to 1.21

* Bump rocksdb version to v8.10.0

* Update kvtool to latest version

* Update gin to v1.9.0

* Use ibctm.ModuleName in app_test

* Fallback to genesis chain id instead of client toml

* Remove all simulations

* Fix cdp migrations issue with v47

* Update dependencies to correct tags

---------

Co-authored-by: Nick DeLuca <nickdeluca08@gmail.com>
2024-02-06 17:54:10 -05:00
Draco
1d4ccf6657
formatting fixes (#1783) 2023-11-21 14:08:07 -05:00
drklee3
395b69ac2f
feat(community): add MsgUpdateParams for governance (#1745)
* Add authority, MsgUpdateParams

* Add e2e test for x/community UpdateParamsMsg proposal

* Ensure new params are different

* Add errors and update codec

* Update changelog

* Use single reused govAuthorityAddr

* Add unit tests for authority and msg

* Validate authority address

* Update proto comment

* Check for ErrInvalidSigner in invalid authority error
2023-10-11 10:22:25 -07:00
drklee3
ae4cb15d73
Emit events for inflation disable and staking rewards (#1743)
* Emit events for staking rewards

* Update test to check disable inflation check

* Only emit staking rewards event when non-zero value

* use existing transfer amount for event

* add assertion that no events are emitted for zero rewards; refactor
event assertions to be a little cleaner

---------

Co-authored-by: Nick DeLuca <nickdeluca08@gmail.com>
2023-10-03 15:10:22 -07:00
Nick DeLuca
102cc0fff3
Community Pool Staking Rewards Implementation & Improvements (#1742)
* add new field upgrade_time_set_staking_rewards_per_second with intention
of integrating into the disable inflation logic to set an initial
staking reward time

* when the disable inflation upgrade time occurs, set the staking rewards
per second to the value specified by the new
upgrade_time_set_staking_rewards_per_second.  This will allow a decoupled
implementation between the ugprade switching logic, and the core
functionality of paying staking rewards from the pool

* add staking rewards state to community keeper and community module
genesis that is required to calculate and track staking reward payouts
accross blocks

* add implementation of staking reward payouts

* remove unused error

* touch up tests and add a test case that fully tests behavior when pool
is drained

* add function comments

* refactor and pull out main calculation to private pure function with
no dependence on keeper

* zero out default parameters -- these are too chain specific to have
useful defaults

* small touch ups on comments, test cases

* use correct Int from sdkmath, not old sdk types; update protonet genesis
for new parmater

* fix copy pasta comment

* use bond denom from staking keeper instead of referncing ukava directly

* add staking reward state for valid genesis

* update kvtool genesis for new params and rewards state
2023-10-03 08:41:54 -07:00
Draco
43be3815cc
feat: disable inflation upgrade logic (#1706)
* feat: disable inflation upgrade logic

* improve disable inflation comments

* add upgrade tests

* update changelog

* split disable inflation upgrade and the upgrade check

* remove pay rewards logic

* clean up incentives test

* add abci test

* refactor upgradeTime and blockTime check

* fix abci test

* fix wrong pr in changelog

* refactor disable inflation tests, behavior, and implementation
  - Unit tests are now shared between keeper and abci begin blocker
    since behavior is 100% the same
  - ABCI is unaware of keeper initial keeper logic branch (keeper
    methods required to be called in certain order by begin blocker)
  - Behavior of zero time is changed -- this now doesn't run for the
    zero time.  This is more ideal for new chains (genesis should set
    all correct state instead of relying on inflation disable logic),
    and allows for a simpler implementation.
  - Begin blocker now panics if parameters are not in state

* remove previous tests and implementation

* remove previous block time keeper state -- not needed for inflation
disalbing

* move inflation disabling to private method and add more comments

* remove unused key

* use correct spelling for idempotence

---------

Co-authored-by: Nick DeLuca <nickdeluca08@gmail.com>
2023-10-02 13:10:22 -07:00
Ruaridh
bc260d8091
feat(community): add switchover param (#1704)
* add community params type

* add get/set params methods

* add community genesis state type

* add community init/export genesis

* add querier methods for params

* add query cli cmd

* update changelog

* update protonet genesis

* Add `RewardsPerSecond` param to `x/community` module (#1707)

* Add RewardsPerSecond param to community

* Update rewards per second param to int

* Add rewards_per_second to protonet genesis

* Use default rewards per second of 744191

* Include value if negative in Validate error

* Rename RewardsPerSecond param to StakingRewardsPerSecond

* Add changelog entry

* Add param migration, update consensus version to 2

* Update proto docs

* Update staking_rewards_per_second param name in protonet genesis (#1730)

* Update godoc

Co-authored-by: Robert Pirtle <Astropirtle@gmail.com>

* add genesis state tests

* document what 0 upgrade time means

* update kvtool to include new params

---------

Co-authored-by: drklee3 <derrick@dlee.dev>
Co-authored-by: Robert Pirtle <Astropirtle@gmail.com>
2023-09-22 09:05:12 -07:00
Robert Pirtle
9a0aed7626
feat(x/metrics): add module for emiting custom chain metrics (#1668)
* initialize x/metrics with metrics collection

* include global labels in x/metrics metrics

* add x/metrics spec

* add x/metrics test coverage

* update changelog
2023-08-25 12:23:53 -07:00
Robert Pirtle
15c243224c
fix(evmutil): create module account on InitGenesis (#1655)
* fix(evmutil): create module account on InitGenesis

ensures the creation of the x/evmutil module account on init genesis.

* update changelog

* cleanup debug logging
2023-07-24 16:00:19 -07:00
Robert Pirtle
49812b6e7c
fix(cli): Resolve problem with assert-invariants cmd (#1624)
* remove no-op migrate command

* move assert-invariants from migrate -> cmd

* fix: don't modify validators for assert-invariants

Makes validator addition in TestApp initialization optional.

* update changelog
2023-06-09 16:52:52 -07:00
Robert Pirtle
528be6350e
feat(evmutil): add CosmosCoinsFullyBackedInvariant (#1610)
* add IterateAllDeployedCosmosCoinContracts method

* refactor unpacking big int from erc20 query

* add QueryERC20TotalSupply method

* feat(evmutil): add CosmosCoinsFullyBackedInvariant

* update changelog
2023-06-05 11:39:53 -07:00
Ruaridh
1459170a37
fix(evmutil): register MsgConvertCosmosCoinToERC20 on amino (#1599)
* add amino registration test

* register evmutil types on app amino codec

* register new msg type in amino and proto,
also use new register method that checks length to catch ledger issues

* clarify variable naming
2023-05-26 19:06:26 -07:00
Robert Pirtle
ff709d73e1
feat(evmutil): add allow list for evm-convertible sdk denoms (#1590)
* add proto for allowed sdk denoms -> evm conversion

* add validation for AllowedNativeCoinERC20Token

* add validation for AllowedNativeCoinERC20Tokens

* add AllowedNativeDenoms into params & genesis

* add evmutil Params.Validate() test

* fix eip712 ante test

* update changelog

* update internal testnet genesis.json

* update state & param specs

updates to the sections describing functionality will be updated once
that functionality actually exists... :)

* update field decimal -> decimals

field now matches erc20 spec

* add validation decimals will cast to uint8

* add v2 store migration for evmutil

* create & register evmutil migrations

* adds migrator to evmutil's keeper
* sets up Migrate1To2 migration
* registers migration in module
* updates GetParams to properly handle historic block queries

* add unit test for GetParams with historic store
2023-05-19 16:01:46 -07:00
Nick DeLuca
31ba0badfc
update ethermint for latest kava version that fixes (#1588)
migration and legacy parameter handling
2023-05-04 10:27:04 -07:00
Robert Pirtle
c5f414e6a5
feat: add community cdp repay debt proposal (#1565)
* add CommunityPoolCDPRepayDebtProposal proto & type

* add cdpKeeper to x/community's keeper

* add handler for CommunityPoolCDPRepayDebtProposal

* more test cases

* rename CommunityPoolCDP -> CommunityCDP

the proposal does not interact with the vanilla community pool

* fix & test stringer

* update changelog
2023-04-20 14:13:16 -07:00
Robert Pirtle
8c1c29a03a
feat: add CommunityPoolLendWithdrawalPermission (#1562)
* feat: add CommunityPoolLendWithdrawalPermission

* update kvtool to master branch

* register with PubProposal legacy amino codec

* register missing legacy amino codec PubProposal
2023-04-18 12:31:43 -07:00
drklee3
56f697fba6
feat: overwrite x/distribution /community_pool endpoint to include x/community balance (#1563)
* Add query path rewrites

* Add test for new x/community endpoint

* Update doc for RegisterAPIRouteRewrites

* Add changelog entry

* Add changelog entry link
2023-04-17 12:54:13 -07:00
drklee3
23e054e402
feat: re-add validator-vesting legacy rest endpoints (#1542)
* Re-add validator-vesting legacy rest endpoints

* Add changelog entry

* Re-add /vesting swagger config
2023-04-06 15:51:34 -07:00
drklee3
82f5ed5c3c
feat: block new vesting create messages (#1539)
* Block new vesting create messages

* doc: Update VestingAccountDecorator doc comment
2023-04-06 13:21:56 -07:00
drklee3
3375484f79
Update deprecated Cosmos methods (#1530)
* Use cosmossdk.io/errors for deprecated error methods

* Update error registration with cosmossdk.io/errors

* Use cosmossdk.io/math for deprecated sdk.Int alias

* Fix modified proto file

* Update sdk.Int usage in swap hooks

* Update e2e test deprecated method usage
2023-04-05 16:21:59 -07:00