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

feat: add bankplus #2

Closed
wants to merge 37 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
b8c4e71
feat: add bankplus
jaeseung-bae Jan 29, 2024
630804b
chore: temporal removal of ci
jaeseung-bae Jan 29, 2024
f4fda42
chore: fix for gosec
jaeseung-bae Jan 29, 2024
90dc958
chore: add bankplus module to go.work.example
jaeseung-bae Jan 29, 2024
ad424fd
chore: update module for DI
jaeseung-bae Jan 29, 2024
8398338
chore: go mod tidy
jaeseung-bae Jan 29, 2024
fce5e38
chore: temporal fix for lint
jaeseung-bae Jan 29, 2024
5b88c40
chore: temporal fix for lint
jaeseung-bae Jan 30, 2024
cbd65c4
chore: should fail
jaeseung-bae Jan 30, 2024
329be07
chore: test-cosmossdk.io/errors
jaeseung-bae Jan 30, 2024
097e08a
chore: test-cosmossdk.io/store
jaeseung-bae Jan 30, 2024
0676b1e
chore: test-cosmossdk.io/core
jaeseung-bae Jan 30, 2024
eb66e1b
chore: should fix lint fail after cosmossdk.io/corev0.12
jaeseung-bae Jan 30, 2024
086afed
chore: after go tidy
jaeseung-bae Jan 30, 2024
503e004
chore: add tests
jaeseung-bae Jan 31, 2024
597637f
Revert "chore: temporal removal of ci"
jaeseung-bae Feb 1, 2024
7c4fa88
Revert "ci: fix pr-labeler"
jaeseung-bae Feb 1, 2024
d7f0808
chore: replace cometbft
jaeseung-bae Feb 1, 2024
616cbbf
chore: add bankplus to pr_labeler
jaeseung-bae Feb 1, 2024
a874e4b
chore: update CHANGELOG
jaeseung-bae Feb 1, 2024
107f7f9
chore: add bankplus test ci
jaeseung-bae Feb 2, 2024
d9ebe72
feat: update x/foundation to use Finschia/cosmos-sdk (#1198)
0Tech Feb 2, 2024
edad7de
chore: fix
jaeseung-bae Feb 2, 2024
cc0e97d
chore: add bankplus module to replace bank module
jaeseung-bae Feb 2, 2024
3ace8bf
chore: fix merge conflict
jaeseung-bae Feb 2, 2024
12fd57e
chore: go mod tidy for tests
jaeseung-bae Feb 5, 2024
d050b22
chore: remove code that use global codec
jaeseung-bae Feb 6, 2024
692d919
Update .github/workflows/test.yml
jaeseung-bae Feb 7, 2024
d5d6bb0
chore: remove code that use global codec from tests
jaeseung-bae Feb 7, 2024
253863c
chore: introduce DeactMultiSend type and DI provider
jaeseung-bae Feb 7, 2024
7c019c6
chore: fix tests
jaeseung-bae Feb 8, 2024
2b363a2
chore: fix init order to apply link prefix codec
jaeseung-bae Feb 8, 2024
840340f
chore: fix side-effect from original bank.send
jaeseung-bae Feb 14, 2024
48fe50f
chore: remove empty bullet
jaeseung-bae Feb 14, 2024
2addae4
chore: replace filter logic with SendRestrictionFn filter
jaeseung-bae Feb 14, 2024
1efcd88
chore: no need to check empty balance. Balance will be back while han…
jaeseung-bae Feb 15, 2024
eab6a0b
chore: remove duplicate private method
jaeseung-bae Feb 16, 2024
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
4 changes: 4 additions & 0 deletions .github/pr_labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,7 @@
# - x/*/client/**/*
# "Type: ADR":
# - docs/architecture/**/*
"C:x/foundation":
- x/foundation/**/*
"C:x/bankplus":
- x/bankplus/**/*
3 changes: 0 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,3 @@ jobs:
- name: Build
if: env.GIT_DIFF
run: GOARCH=${{ matrix.go-arch }} make build
- name: Build Legacy
if: env.GIT_DIFF
run: GOARCH=${{ matrix.go-arch }} COSMOS_BUILD_OPTIONS=legacy make build
2 changes: 1 addition & 1 deletion .github/workflows/proto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,4 @@ jobs:
- uses: bufbuild/buf-breaking-action@v1
with:
input: "proto"
against: "https://github.com/${{ github.repository }}.git#branch=${{ github.event.pull_request.base.ref }},ref=HEAD~1,subdir=proto"
against: "https://github.com/${{ github.repository }}.git#branch=${{ github.event.pull_request.base.ref }},subdir=proto"
140 changes: 99 additions & 41 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,40 +113,41 @@ jobs:
# name: "${{ github.sha }}-integration-coverage"
# path: ./tests/integration-profile.out

# test-e2e:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
# - uses: actions/setup-go@v4
# with:
# go-version: "1.21"
# check-latest: true
# cache: true
# cache-dependency-path: go.sum
# - uses: technote-space/get-diff-action@v6.1.2
# id: git_diff
# with:
# PATTERNS: |
# **/*.go
# go.mod
# go.sum
# **/go.mod
# **/go.sum
# **/Makefile
# Makefile
# - name: e2e tests
# if: env.GIT_DIFF
# run: |
# make test-e2e-cov
# - uses: actions/upload-artifact@v3
# if: env.GIT_DIFF
# with:
# name: "${{ github.sha }}-e2e-coverage"
# path: ./tests/e2e-profile.out
test-e2e:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: "1.21"
check-latest: true
cache: true
cache-dependency-path: go.sum
- uses: technote-space/get-diff-action@v6.1.2
id: git_diff
with:
PATTERNS: |
**/*.go
go.mod
go.sum
**/go.mod
**/go.sum
**/Makefile
Makefile
- name: e2e tests
if: env.GIT_DIFF
run: |
make test-e2e-cov
- uses: actions/upload-artifact@v3
if: env.GIT_DIFF
with:
name: "${{ github.sha }}-e2e-coverage"
path: ./tests/e2e-profile.out

repo-analysis:
runs-on: ubuntu-latest
needs: [tests, test-integration, test-e2e]
# needs: [tests, test-integration, test-e2e]
needs: [ tests, test-e2e ]
steps:
- uses: actions/checkout@v3
- uses: technote-space/get-diff-action@v6.1.2
Expand Down Expand Up @@ -178,11 +179,11 @@ jobs:
# if: env.GIT_DIFF
# with:
# name: "${{ github.sha }}-integration-coverage"
# - uses: actions/download-artifact@v3
# if: env.GIT_DIFF
# with:
# name: "${{ github.sha }}-e2e-coverage"
# continue-on-error: true
- uses: actions/download-artifact@v3
if: env.GIT_DIFF
with:
name: "${{ github.sha }}-e2e-coverage"
continue-on-error: true
- name: sonarcloud
if: ${{ env.GIT_DIFF && !github.event.pull_request.draft }}
uses: SonarSource/sonarcloud-github-action@master
Expand Down Expand Up @@ -276,11 +277,6 @@ jobs:
run: |
cd simapp
go test -mod=readonly -timeout 30m -coverprofile=coverage.out -covermode=atomic -tags='norace ledger test_ledger_mock rocksdb_build' ./...
- name: tests simapp v1
if: env.GIT_DIFF
run: |
cd simapp
go test -mod=readonly -timeout 30m -tags='app_v1 norace ledger test_ledger_mock rocksdb_build' ./...
- name: sonarcloud
if: ${{ env.GIT_DIFF && !github.event.pull_request.draft && env.SONAR_TOKEN != null }}
uses: SonarSource/sonarcloud-github-action@master
Expand All @@ -296,3 +292,65 @@ jobs:

# NOTE: The following jobs are used to test the Finschia SDK Go submodules present under x/{module}.
# They run when there is a diff in their respective directories.

test-x-foundation:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: "1.21"
check-latest: true
cache: true
cache-dependency-path: x/foundation/go.sum
- uses: technote-space/get-diff-action@v6.1.2
id: git_diff
with:
PATTERNS: |
x/foundation/**/*.go
x/foundation/go.mod
x/foundation/go.sum
- name: tests
if: env.GIT_DIFF
run: |
cd x/foundation
go test -mod=readonly -timeout 30m -coverprofile=coverage.out -covermode=atomic -tags='norace ledger test_ledger_mock rocksdb_build' ./...
- 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: x/foundation/

test-x-bankplus:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: "1.21"
check-latest: true
cache: true
cache-dependency-path: x/bankplus/go.sum
- uses: technote-space/get-diff-action@v6.1.2
id: git_diff
with:
PATTERNS: |
x/bankplus/**/*.go
x/bankplus/go.mod
x/bankplus/go.sum
- name: tests
if: env.GIT_DIFF
run: |
cd x/bankplus
go test -mod=readonly -timeout 30m -coverprofile=coverage.out -covermode=atomic -tags='norace ledger test_ledger_mock rocksdb_build' ./...
- 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: x/bankplus/
4 changes: 4 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ issues:
- text: "SA1019: codec.NewAminoCodec is deprecated" # TODO remove once migration path is set out
linters:
- staticcheck
- path: "client/cli" # TODO(@0Tech): remove after foundation exec proposal removed
text: "SA1019: govcli.FlagDescription is deprecated"
linters:
- staticcheck
- text: "leading space"
linters:
- nolintlint
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,12 @@ Ref: https://keepachangelog.com/en/1.0.0/
## [Unreleased](https://github.com/Finschia/finschia-sdk/compare/v0.48.0...HEAD)

### Features

* (x/foundation) [\#1198](https://github.com/Finschia/finschia-sdk/pull/1198) update x/foundation to use
Finschia/cosmos-sdk
* (all) [\#1205](https://github.com/Finschia/finschia-sdk/pull/1205) delegate native logics to Finschia/cosmos-sdk
* (consensus) [\#1178](https://github.com/Finschia/finschia-sdk/pull/1178) change the consensus from Ostracon to Tendermint v0.34.24
* (x/bankplus) [\#1223](https://github.com/Finschia/finschia-sdk/pull/1223) update x/bankplus to use Finschia/cosmos-sdk

### Improvements
* (docs) [\#1120](https://github.com/Finschia/finschia-sdk/pull/1120) Update links in x/foundation README.md
Expand Down
2 changes: 1 addition & 1 deletion api/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ go 1.21
toolchain go1.21.5

require (
cosmossdk.io/api v0.7.2
github.com/cosmos/cosmos-proto v1.0.0-beta.3
github.com/cosmos/cosmos-sdk v0.50.2
github.com/cosmos/gogoproto v1.4.11
Expand All @@ -14,7 +15,6 @@ require (
)

require (
cosmossdk.io/api v0.7.2 // indirect
cosmossdk.io/collections v0.4.0 // indirect
cosmossdk.io/core v0.11.0 // indirect
cosmossdk.io/depinject v1.0.0-alpha.4 // indirect
Expand Down
Loading
Loading