Skip to content

Commit

Permalink
fix: update deposit authorization with with unused amount
Browse files Browse the repository at this point in the history
fixes akash-network/support#88

Signed-off-by: Artur Troian <[email protected]>
  • Loading branch information
troian committed Apr 22, 2024
1 parent debe78a commit d3c2582
Show file tree
Hide file tree
Showing 30 changed files with 896 additions and 704 deletions.
1 change: 1 addition & 0 deletions app/app_configure.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ func (app *AkashApp) setAkashKeepers() {
app.Keepers.Cosmos.Bank,
app.Keepers.Akash.Take,
app.Keepers.Cosmos.Distr,
app.Keepers.Cosmos.Authz,
)

app.Keepers.Akash.Deployment = deployment.NewKeeper(
Expand Down
4 changes: 2 additions & 2 deletions app/types/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import (
akeeper "github.com/akash-network/node/x/audit/keeper"
ckeeper "github.com/akash-network/node/x/cert/keeper"
dkeeper "github.com/akash-network/node/x/deployment/keeper"
escrowkeeper "github.com/akash-network/node/x/escrow/keeper"
ekeeper "github.com/akash-network/node/x/escrow/keeper"
agovkeeper "github.com/akash-network/node/x/gov/keeper"
ikeeper "github.com/akash-network/node/x/inflation/keeper"
mkeeper "github.com/akash-network/node/x/market/keeper"
Expand Down Expand Up @@ -60,7 +60,7 @@ type AppKeepers struct {
}

Akash struct {
Escrow escrowkeeper.Keeper
Escrow ekeeper.Keeper
Deployment dkeeper.IKeeper
Take tkeeper.IKeeper
Market mkeeper.IKeeper
Expand Down
5 changes: 2 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ module github.com/akash-network/node
go 1.21

require (
github.com/akash-network/akash-api v0.0.61
github.com/akash-network/akash-api v0.0.65
github.com/blang/semver/v4 v4.0.0
github.com/boz/go-lifecycle v0.1.1
github.com/cosmos/cosmos-sdk v0.45.16
github.com/cosmos/ibc-go/v4 v4.6.0
github.com/cosmos/ibc-go/v4 v4.6.0
github.com/cosmos/go-bip39 v1.0.0
github.com/gogo/protobuf v1.3.3
github.com/google/go-github/v56 v56.0.0
github.com/gorilla/mux v1.8.1
Expand Down Expand Up @@ -97,7 +97,6 @@ require (
github.com/cosmos/btcutil v1.0.4 // indirect
github.com/cosmos/cosmos-db v0.0.0-20221226095112-f3c38ecb5e32 // indirect
github.com/cosmos/cosmos-proto v1.0.0-beta.1 // indirect
github.com/cosmos/go-bip39 v1.0.0 // indirect
github.com/cosmos/gorocksdb v1.2.0 // indirect
github.com/cosmos/iavl v0.19.5 // indirect
github.com/cosmos/ledger-cosmos-go v0.12.2 // indirect
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBA
github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5/go.mod h1:SkGFH1ia65gfNATL8TAiHDNxPzPdmEL5uirI2Uyuz6c=
github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY=
github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw=
github.com/akash-network/akash-api v0.0.61 h1:Hj/IBr9cFMsFs4VjymLZCoX/5dNfZSFd4iFwUSqhBtQ=
github.com/akash-network/akash-api v0.0.61/go.mod h1:pNr61L4+0sheol7ZK0HjgK3rxpIAbYBGq1w1oH4B0+M=
github.com/akash-network/akash-api v0.0.65 h1:Jadkbu9rvE5UIrd2t0FRbEGMeco/KUEzD/8w6zqxPlI=
github.com/akash-network/akash-api v0.0.65/go.mod h1:pNr61L4+0sheol7ZK0HjgK3rxpIAbYBGq1w1oH4B0+M=
github.com/akash-network/cometbft v0.34.27-akash h1:V1dApDOr8Ee7BJzYyQ7Z9VBtrAul4+baMeA6C49dje0=
github.com/akash-network/cometbft v0.34.27-akash/go.mod h1:BcCbhKv7ieM0KEddnYXvQZR+pZykTKReJJYf7YC7qhw=
github.com/akash-network/ledger-go v0.14.3 h1:LCEFkTfgGA2xFMN2CtiKvXKE7dh0QSM77PJHCpSkaAo=
Expand Down
2 changes: 1 addition & 1 deletion make/init.mk
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ endif
GOLANGCI_LINT_VERSION ?= v1.51.2
STATIK_VERSION ?= v0.1.7
GIT_CHGLOG_VERSION ?= v0.15.1
MOCKERY_VERSION ?= 2.24.0
MOCKERY_VERSION ?= 2.42.0
COSMOVISOR_VERSION ?= v1.5.0

# ==== Build tools version tracking ====
Expand Down
5 changes: 1 addition & 4 deletions make/test-upgrade.mk
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@ export AKASH_LOG_COLOR = true

KEY_OPTS := --keyring-backend=$(AKASH_KEYRING_BACKEND)
KEY_NAME ?= validator
#UPGRADE_TO ?= $(shell $(ROOT_DIR)/script/upgrades.sh test-required $(RELEASE_TAG))
UPGRADE_TO ?= $(shell $(ROOT_DIR)/script/upgrades.sh upgrade-from-release $(RELEASE_TAG))
# v0.28.0
UPGRADE_FROM := $(shell cat $(ROOT_DIR)/meta.json | jq -r --arg name $(UPGRADE_TO) '.upgrades[$$name].from_version' | tr -d '\n')
GENESIS_BINARY_VERSION := $(shell cat $(ROOT_DIR)/meta.json | jq -r --arg name $(UPGRADE_TO) '.upgrades[$$name].from_binary' | tr -d '\n')
UPGRADE_BINARY_VERSION ?= local
Expand All @@ -26,8 +24,7 @@ $(AKASH_INIT):
touch $@

.PHONY: init
init: $(AKASH_INIT)

init: $(AKASH_INIT) $(COSMOVISOR)

.PHONY: genesis
genesis: $(GENESIS_DEST)
Expand Down
5 changes: 5 additions & 0 deletions meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@
"skipped": false,
"from_binary": "v0.30.3",
"from_version": "v0.30.0"
},
"v0.34.0": {
"skipped": false,
"from_binary": "v0.32.3",
"from_version": "v0.32.0"
}
}
}
4 changes: 4 additions & 0 deletions tests/upgrade/upgrade-v0.34.0.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"migrations": {
}
}
Loading

0 comments on commit d3c2582

Please sign in to comment.