Skip to content

Commit

Permalink
Merge pull request #75 from bnb-chain/develop
Browse files Browse the repository at this point in the history
release: prepare for release v0.0.1
  • Loading branch information
unclezoro authored Dec 26, 2022
2 parents eb1e3eb + b9169c2 commit 4c0ab44
Show file tree
Hide file tree
Showing 297 changed files with 8,595 additions and 5,197 deletions.
53 changes: 10 additions & 43 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,50 +1,17 @@
<!--
The default pull request template is for types feat, fix, or refactor.
For other templates, add one of the following parameters to the url:
- template=docs.md
- template=other.md
-->
### Description

## Description
add a description of your changes here...

Closes: #XXXX
### Rationale

<!-- Add a description of the changes that this PR introduces and the files that
are the most critical to review. -->
tell us why we need these changes...

---
### Example

### Author Checklist
add an example CLI or API response...

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*
### Changes

I have...

- [ ] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] added `!` to the type prefix if API or client breaking change
- [ ] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/main/CONTRIBUTING.md#pr-targeting))
- [ ] provided a link to the relevant issue or specification
- [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/main/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/main/CONTRIBUTING.md#testing)
- [ ] added a changelog entry to `CHANGELOG.md`
- [ ] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] updated the relevant documentation or specification
- [ ] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)
Notable changes:
* add each change in a bullet point here
* ...
62 changes: 0 additions & 62 deletions .github/dependabot.yml

This file was deleted.

57 changes: 0 additions & 57 deletions .github/workflows/codeql-analysis.yml

This file was deleted.

59 changes: 59 additions & 0 deletions .github/workflows/codeql-analysis.yml.tmp
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
## Should be open after open-source

# name: "CodeQL"

# on:
# pull_request:
# paths:
# - "**.go"
# push:
# branches:
# - main
# - release/**
# paths:
# - "**.go"

# jobs:
# analyze:
# name: Analyze
# runs-on: ubuntu-latest
# permissions:
# actions: read
# contents: read
# security-events: write

# steps:
# - name: Checkout repository
# uses: actions/checkout@v3
# - uses: actions/setup-go@v3
# with:
# go-version: 1.18
# # Initializes the CodeQL tools for scanning.
# - name: Initialize CodeQL
# uses: github/codeql-action/init@v2
# with:
# languages: "go"
# queries: crypto-com/cosmos-sdk-codeql@main,security-and-quality
# # If you wish to specify custom queries, you can do so here or in a config file.
# # By default, queries listed here will override any specified in a config file.
# # Prefix the list here with "+" to use these queries and those in the config file.
# # queries: ./path/to/local/query, your-org/your-repo/queries@main

# # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# # If this step fails, then you should remove it and run the build manually (see below)
# - name: Autobuild
# uses: github/codeql-action/autobuild@v2

# # ℹ️ Command-line programs to run using the OS shell.
# # 📚 https://git.io/JvXDl

# # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# # and modify them (or add more) to build your code if your project
# # uses a compiled language

# #- run: |
# # make bootstrap
# # make release

# - name: Perform CodeQL Analysis
# uses: github/codeql-action/analyze@v2
14 changes: 0 additions & 14 deletions .github/workflows/dependencies-review.yml

This file was deleted.

16 changes: 16 additions & 0 deletions .github/workflows/dependencies-review.yml.tmp
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
## Should be open after open-source

# name: "Dependency Review"
# on: [pull_request]

# permissions:
# contents: read

# jobs:
# dependency-review:
# runs-on: ubuntu-latest
# steps:
# - name: "Checkout Repository"
# uses: actions/checkout@v3
# - name: "Dependency Review"
# uses: actions/dependency-review-action@v1
14 changes: 14 additions & 0 deletions .github/workflows/lint-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,17 @@ jobs:
- uses: amannn/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
types: |
feat
fix
docs
style
refactor
perf
test
build
ci
chore
revert
release
4 changes: 4 additions & 0 deletions .github/workflows/test-race.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ on:
permissions:
contents: read

env:
CGO_CFLAGS: "-O -D__BLST_PORTABLE__"
CGO_CFLAGS_ALLOW: "-O -D__BLST_PORTABLE__"

jobs:
cleanup-runs:
runs-on: ubuntu-latest
Expand Down
28 changes: 6 additions & 22 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ on:
permissions:
contents: read

env:
CGO_CFLAGS: "-O -D__BLST_PORTABLE__"
CGO_CFLAGS_ALLOW: "-O -D__BLST_PORTABLE__"

jobs:
cleanup-runs:
runs-on: ubuntu-latest
Expand All @@ -22,7 +26,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
go-arch: ["amd64", "arm", "arm64"]
go-arch: ["amd64"]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
Expand All @@ -38,9 +42,6 @@ jobs:
- name: Build
run: GOARCH=${{ matrix.go-arch }} LEDGER_ENABLED=false make build

- name: Build cosmovisor
run: GOARCH=${{ matrix.go-arch }} LEDGER_ENABLED=false make cosmovisor

test-submodules:
runs-on: ubuntu-latest
container: tendermintdev/docker-tm-db-testing
Expand Down Expand Up @@ -177,23 +178,6 @@ jobs:
file: ./coverage.txt
if: env.GIT_DIFF

test-rosetta:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v3
- uses: technote-space/[email protected]
id: git_diff
with:
PATTERNS: |
**/**.go
go.mod
go.sum
- name: test rosetta
run: |
make test-rosetta
# if: env.GIT_DIFF

liveness-test:
runs-on: ubuntu-latest
timeout-minutes: 15
Expand All @@ -211,7 +195,7 @@ jobs:
go.sum
- name: start localnet
run: |
make clean localnet-start
ENABLE_ROCKSDB=true make clean localnet-start
if: env.GIT_DIFF
- name: test liveness
run: |
Expand Down
5 changes: 5 additions & 0 deletions baseapp/abci.go
Original file line number Diff line number Diff line change
Expand Up @@ -709,6 +709,11 @@ func (app *BaseApp) GetBlockRetentionHeight(commitHeight int64) int64 {
return retentionHeight
}

// SetMockBlockHeight is only used for testing.
func (app *BaseApp) SetMockBlockHeight(height int64) {
app.deliverState.ctx = app.deliverState.ctx.WithBlockHeight(height)
}

func handleQueryApp(app *BaseApp, path []string, req abci.RequestQuery) abci.ResponseQuery {
if len(path) >= 2 {
switch path[1] {
Expand Down
2 changes: 1 addition & 1 deletion baseapp/block_gas_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ func TestBaseApp_BlockGas(t *testing.T) {
require.Equal(t, []byte("ok"), okValue)
}
// check block gas is always consumed
baseGas := uint64(70184) // baseGas is the gas consumed before tx msg
baseGas := uint64(74343) // baseGas is the gas consumed before tx msg
expGasConsumed := addUint64Saturating(tc.gasToConsume, baseGas)
if expGasConsumed > txtypes.MaxGasWanted {
// capped by gasLimit
Expand Down
Loading

0 comments on commit 4c0ab44

Please sign in to comment.