Skip to content

Commit

Permalink
Merge pull request #410 from sge-network/release/v1.7.x
Browse files Browse the repository at this point in the history
Release / v1.7.1
  • Loading branch information
scorpioborn authored Jun 20, 2024
2 parents cc22634 + be36271 commit c293d88
Show file tree
Hide file tree
Showing 156 changed files with 8,364 additions and 1,542 deletions.
2 changes: 1 addition & 1 deletion .github/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 0

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/proto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v4
- uses: technote-space/get-diff-action@v4
with:
PATTERNS: |
Expand Down
36 changes: 19 additions & 17 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,12 @@ jobs:
arch: arm64

steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Get git diff
uses: technote-space/get-diff-action@v6.1.2
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: 1.22
- uses: technote-space/get-diff-action@v4
id: git_diff
with:
PATTERNS: |
**/**.wasm
Expand Down Expand Up @@ -82,23 +84,23 @@ jobs:
go-version: 1.22
- uses: actions/checkout@v4
- name: Create a file with all the pkgs
run: go list ./... > pkgs.txt
run: go list ./... | grep -E -v 'tests/e2e' > pkgs.txt
- name: Split pkgs into 4 files
run: split -d -n l/4 pkgs.txt pkgs.txt.part.
# cache multiple
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
with:
name: "${{ github.sha }}-00"
path: ./pkgs.txt.part.00
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
with:
name: "${{ github.sha }}-01"
path: ./pkgs.txt.part.01
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
with:
name: "${{ github.sha }}-02"
path: ./pkgs.txt.part.02
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
with:
name: "${{ github.sha }}-03"
path: ./pkgs.txt.part.03
Expand All @@ -121,15 +123,15 @@ jobs:
**/**.go
go.mod
go.sum
- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v4
with:
name: "${{ github.sha }}-${{ matrix.part }}"
if: env.GIT_DIFF
- name: test & coverage report creation
run: |
cat pkgs.txt.part.${{ matrix.part }} | xargs go test -mod=readonly -timeout 30m -coverprofile=${{ matrix.part }}profile.out -covermode=atomic -tags='norace ledger test_ledger_mock'
if: env.GIT_DIFF
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
with:
name: "${{ github.sha }}-${{ matrix.part }}-coverage"
path: ./${{ matrix.part }}profile.out
Expand All @@ -145,19 +147,19 @@ jobs:
**/**.go
go.mod
go.sum
- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v4
with:
name: "${{ github.sha }}-00-coverage"
if: env.GIT_DIFF
- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v4
with:
name: "${{ github.sha }}-01-coverage"
if: env.GIT_DIFF
- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v4
with:
name: "${{ github.sha }}-02-coverage"
if: env.GIT_DIFF
- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v4
with:
name: "${{ github.sha }}-03-coverage"
if: env.GIT_DIFF
Expand Down Expand Up @@ -199,15 +201,15 @@ jobs:
**/**.go
go.mod
go.sum
- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v4
with:
name: "${{ github.sha }}-${{ matrix.part }}"
if: env.GIT_DIFF
- name: test & coverage report creation
run: |
xargs --arg-file=pkgs.txt.part.${{ matrix.part }} go test -mod=readonly -timeout 30m -race -tags='cgo ledger test_ledger_mock'
if: env.GIT_DIFF
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
with:
name: "${{ github.sha }}-${{ matrix.part }}-race-output"
path: ./${{ matrix.part }}-race-output.txt
18 changes: 2 additions & 16 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,7 @@ import (
"github.com/sge-network/sge/app/keepers"
sgeappparams "github.com/sge-network/sge/app/params"
"github.com/sge-network/sge/app/upgrades"
v1 "github.com/sge-network/sge/app/upgrades/v1"
v2 "github.com/sge-network/sge/app/upgrades/v2"
v3 "github.com/sge-network/sge/app/upgrades/v3"
v4 "github.com/sge-network/sge/app/upgrades/v4"
v5 "github.com/sge-network/sge/app/upgrades/v5"
v6 "github.com/sge-network/sge/app/upgrades/v6"
v7 "github.com/sge-network/sge/app/upgrades/v7"
v8 "github.com/sge-network/sge/app/upgrades/v8"
v10 "github.com/sge-network/sge/app/upgrades/v10"
v9 "github.com/sge-network/sge/app/upgrades/v9"

// unnamed import of statik for swagger UI support
Expand All @@ -86,15 +79,8 @@ var (
// DefaultNodeHome default home directories for the application daemon
DefaultNodeHome string
Upgrades = []upgrades.Upgrade{
v1.Upgrade,
v2.Upgrade,
v3.Upgrade,
v4.Upgrade,
v5.Upgrade,
v6.Upgrade,
v7.Upgrade,
v8.Upgrade,
v9.Upgrade,
v10.Upgrade,
}
)

Expand Down
8 changes: 8 additions & 0 deletions app/keepers/keepers.go
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,7 @@ func NewAppKeeper(
BankKeeper: appKeepers.BankKeeper,
},
authtypes.FeeCollectorName,
govModAddress,
)

appKeepers.DistrKeeper = distrkeeper.NewKeeper(
Expand Down Expand Up @@ -486,20 +487,23 @@ func NewAppKeeper(
AccountKeeper: appKeepers.AccountKeeper,
FeeGrantKeeper: appKeepers.FeeGrantKeeper,
},
govModAddress,
)

appKeepers.OVMKeeper = ovmmodulekeeper.NewKeeper(
appCodec,
appKeepers.keys[ovmmoduletypes.StoreKey],
appKeepers.keys[ovmmoduletypes.MemStoreKey],
appKeepers.GetSubspace(ovmmoduletypes.ModuleName),
govModAddress,
)

appKeepers.MarketKeeper = marketmodulekeeper.NewKeeper(
appCodec,
appKeepers.keys[marketmoduletypes.StoreKey],
appKeepers.keys[marketmoduletypes.MemStoreKey],
appKeepers.GetSubspace(marketmoduletypes.ModuleName),
govModAddress,
)
appKeepers.MarketKeeper.SetOVMKeeper(appKeepers.OVMKeeper)
appKeepers.MarketKeeper.SetOrderbookKeeper(appKeepers.OrderbookKeeper)
Expand All @@ -509,6 +513,7 @@ func NewAppKeeper(
appKeepers.keys[betmoduletypes.StoreKey],
appKeepers.keys[betmoduletypes.MemStoreKey],
appKeepers.GetSubspace(betmoduletypes.ModuleName),
govModAddress,
)
appKeepers.BetKeeper.SetMarketKeeper(appKeepers.MarketKeeper)
appKeepers.BetKeeper.SetOrderbookKeeper(appKeepers.OrderbookKeeper)
Expand All @@ -527,6 +532,7 @@ func NewAppKeeper(
housemodulekeeper.SdkExpectedKeepers{
AuthzKeeper: appKeepers.AuthzKeeper,
},
govModAddress,
)
appKeepers.OrderbookKeeper.SetHouseKeeper(appKeepers.HouseKeeper)

Expand All @@ -540,6 +546,7 @@ func NewAppKeeper(
appKeepers.BetKeeper,
appKeepers.OrderbookKeeper,
appKeepers.HouseKeeper,
govModAddress,
)

appKeepers.RewardKeeper = rewardmodulekeeper.NewKeeper(
Expand All @@ -555,6 +562,7 @@ func NewAppKeeper(
BankKeeper: appKeepers.BankKeeper,
AccountKeeper: appKeepers.AccountKeeper,
},
govModAddress,
)

// ** Hooks ** \\
Expand Down
25 changes: 0 additions & 25 deletions app/upgrades/v1/consts.go

This file was deleted.

47 changes: 0 additions & 47 deletions app/upgrades/v1/upgrades.go

This file was deleted.

6 changes: 3 additions & 3 deletions app/upgrades/v7/consts.go → app/upgrades/v10/consts.go
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package v7
package v10

import (
store "github.com/cosmos/cosmos-sdk/store/types"

"github.com/sge-network/sge/app/upgrades"
)

// UpgradeName defines the on-chain upgrade name for the v1.5.3 upgrade.
const UpgradeName = "v1.5.3"
// UpgradeName defines the on-chain upgrade name for the v1.7.1 upgrade.
const UpgradeName = "v1.7.1"

var Upgrade = upgrades.Upgrade{
UpgradeName: UpgradeName,
Expand Down
3 changes: 2 additions & 1 deletion app/upgrades/v5/upgrades.go → app/upgrades/v10/upgrades.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package v5
package v10

import (
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/module"
upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types"

"github.com/sge-network/sge/app/keepers"
)

Expand Down
19 changes: 0 additions & 19 deletions app/upgrades/v2/consts.go

This file was deleted.

39 changes: 0 additions & 39 deletions app/upgrades/v2/upgrades.go

This file was deleted.

Loading

0 comments on commit c293d88

Please sign in to comment.