Skip to content

Commit

Permalink
chore: keep in release branch only sdk versioned software 2/2 (#21140)
Browse files Browse the repository at this point in the history
  • Loading branch information
julienrbrt authored Aug 2, 2024
1 parent bad0add commit 580af8b
Show file tree
Hide file tree
Showing 809 changed files with 674 additions and 666,757 deletions.
4 changes: 0 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,5 @@ jobs:
###################
## Build Tooling ##
###################
- name: Build Cosmovisor
run: GOARCH=${{ matrix.go-arch }} make cosmovisor
- name: Build Confix
run: GOARCH=${{ matrix.go-arch }} make confix
- name: Build Hubl
run: GOARCH=${{ matrix.go-arch }} make hubl
98 changes: 98 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -479,6 +479,36 @@ jobs:
with:
projectBaseDir: schema/

test-schema-testing:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: "1.22"
cache: true
cache-dependency-path: schema/testing/go.sum
- uses: technote-space/[email protected]
id: git_diff
with:
PATTERNS: |
schema/testing/**/*.go
schema/testing/go.mod
schema/testing/go.sum
- name: tests
if: env.GIT_DIFF
run: |
cd schema
go test -mod=readonly -timeout 30m -coverprofile=coverage.out -covermode=atomic ./...
- name: sonarcloud
if: ${{ env.GIT_DIFF && !github.event.pull_request.draft && env.SONAR_TOKEN != null }}
uses: SonarSource/sonarcloud-github-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
with:
projectBaseDir: schema/testing/

test-indexer-postgres:
runs-on: ubuntu-latest
steps:
Expand Down Expand Up @@ -740,6 +770,74 @@ jobs:
with:
projectBaseDir: tools/hubl/

test-store:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- uses: actions/setup-go@v5
with:
go-version: "1.20"
check-latest: true
cache: true
cache-dependency-path: store/go.sum
- uses: technote-space/[email protected]
id: git_diff
with:
PATTERNS: |
store/**/*.go
store/go.mod
store/go.sum
- name: tests
if: env.GIT_DIFF
run: |
cd store
nix develop .. -c go test -mod=readonly -timeout 30m -coverprofile=coverage.out -covermode=atomic -tags='norace ledger test_ledger_mock rocksdb' ./...
- name: sonarcloud
if: ${{ env.GIT_DIFF && !github.event.pull_request.draft && env.SONAR_TOKEN != null }}
uses: SonarSource/sonarcloud-github-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
with:
projectBaseDir: store/

test-store-v2:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- uses: actions/setup-go@v5
with:
go-version: "1.22"
check-latest: true
cache: true
cache-dependency-path: store/v2/go.sum
- uses: technote-space/[email protected]
id: git_diff
with:
PATTERNS: |
store/v2/**/*.go
store/v2/go.mod
store/v2/go.sum
- name: test & coverage report creation
if: env.GIT_DIFF
run: |
cd store/v2
nix develop .. -c go test -mod=readonly -timeout 30m -coverprofile=coverage.out -covermode=atomic -tags='norace ledger test_ledger_mock rocksdb' ./...
- name: sonarcloud
if: ${{ env.GIT_DIFF && !github.event.pull_request.draft && env.SONAR_TOKEN != null }}
uses: SonarSource/sonarcloud-github-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
with:
projectBaseDir: store/v2/

test-log:
runs-on: ubuntu-latest
steps:
Expand Down
72 changes: 72 additions & 0 deletions .github/workflows/v2-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,78 @@ concurrency:
cancel-in-progress: true

jobs:
server-v2:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: "1.22"
check-latest: true
cache: true
cache-dependency-path: go.sum
- uses: technote-space/[email protected]
id: git_diff
with:
PATTERNS: |
server/v2/*.go
server/v2/go.mod
server/v2/go.sum
server/v2/testdata/*.toml
- name: test & coverage report creation
if: env.GIT_DIFF
run: |
cd server/v2 && go test -mod=readonly -race -timeout 30m -tags='ledger test_ledger_mock'
stf:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: "1.22"
check-latest: true
cache: true
cache-dependency-path: go.sum
- uses: technote-space/[email protected]
id: git_diff
with:
PATTERNS: |
server/v2/stf/**/*.go
server/v2/stf/go.mod
server/v2/stf/go.sum
- name: test & coverage report creation
if: env.GIT_DIFF
run: |
cd server/v2/stf && go test -mod=readonly -race -timeout 30m -tags='ledger test_ledger_mock'
appmanager:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: "1.22"
check-latest: true
cache: true
cache-dependency-path: go.sum
- uses: technote-space/[email protected]
id: git_diff
with:
PATTERNS: |
server/v2/appmanager/**/*.go
server/v2/appmanager/go.mod
server/v2/appmanager/go.sum
- name: test & coverage report creation
if: env.GIT_DIFF
run: |
cd server/v2/appmanager && go test -mod=readonly -race -timeout 30m -tags='ledger test_ledger_mock'
cometbft:
runs-on: ubuntu-latest
strategy:
Expand Down
10 changes: 0 additions & 10 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,7 @@ WORKDIR /go/src/github.com/cosmos/cosmos-sdk

# optimization: if go.sum didn't change, docker will use cached image
COPY go.mod go.sum ./
COPY math/go.mod math/go.sum ./math/
COPY api/go.mod api/go.sum ./api/
COPY core/go.mod core/go.sum ./core/
COPY collections/go.mod collections/go.sum ./collections/
COPY store/go.mod store/go.sum ./store/
COPY x/accounts/go.mod x/accounts/go.sum ./x/accounts/
COPY x/tx/go.mod x/tx/go.sum /x/tx/
COPY x/protocolpool/go.mod x/protocolpool/go.sum ./x/protocolpool/
COPY x/gov/go.mod x/gov/go.sum ./x/gov/
COPY x/distribution/go.mod x/distribution/go.sum ./x/distribution/
Expand All @@ -39,11 +33,7 @@ COPY x/auth/go.mod x/auth/go.sum ./x/auth/
COPY x/authz/go.mod x/authz/go.sum ./x/authz/
COPY x/bank/go.mod x/bank/go.sum ./x/bank/
COPY x/mint/go.mod x/mint/go.sum ./x/mint/
COPY x/tx/go.mod x/tx/go.sum ./x/tx/
COPY x/consensus/go.mod x/consensus/go.sum ./x/consensus/
COPY depinject/go.mod depinject/go.sum ./depinject/
COPY core/testing/go.mod core/testing/go.sum ./core/testing/
COPY log/go.mod log/go.sum ./log/
RUN go mod download

# Add source files
Expand Down
Loading

0 comments on commit 580af8b

Please sign in to comment.