Skip to content

Commit 859186f

Browse files
authored
Merge pull request #743 from binance-chain/develop
[R4R] Release v1.1.8
2 parents 74f6b61 + 21a3b11 commit 859186f

File tree

143 files changed

+6408
-1856
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

143 files changed

+6408
-1856
lines changed

.github/generate_change_log.sh

+8
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,10 @@ TESTNET_ZIP_SUM="$(checksum ./testnet.zip)"
2424
LINUX_BIN_SUM="$(checksum ./linux/geth)"
2525
MAC_BIN_SUM="$(checksum ./macos/geth)"
2626
WINDOWS_BIN_SUM="$(checksum ./windows/geth.exe)"
27+
ARM5_BIN_SUM="$(checksum ./arm5/geth-linux-arm-5)"
28+
ARM6_BIN_SUM="$(checksum ./arm6/geth-linux-arm-6)"
29+
ARM7_BIN_SUM="$(checksum ./arm7/geth-linux-arm-7)"
30+
ARM64_BIN_SUM="$(checksum ./arm64/geth-linux-arm64)"
2731
OUTPUT=$(cat <<-END
2832
## Changelog\n
2933
${CHANGE_LOG}\n
@@ -35,6 +39,10 @@ ${CHANGE_LOG}\n
3539
| geth_linux | ${LINUX_BIN_SUM} |\n
3640
| geth_mac | ${MAC_BIN_SUM} |\n
3741
| geth_windows | ${WINDOWS_BIN_SUM} |\n
42+
| geth_linux_arm5 | ${ARM5_BIN_SUM} |\n
43+
| geth_linux_arm6 | ${ARM6_BIN_SUM} |\n
44+
| geth_linux_arm7 | ${ARM7_BIN_SUM} |\n
45+
| geth_linux_arm64 | ${ARM64_BIN_SUM} |\n
3846
END
3947
)
4048

.github/release.env

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
MAINNET_FILE_URL="https://github.com/binance-chain/bsc/releases/download/v1.1.6/mainnet.zip"
2-
TESTNET_FILE_URL="https://github.com/binance-chain/bsc/releases/download/v1.1.6/testnet.zip"
1+
MAINNET_FILE_URL="https://github.com/binance-chain/bsc/releases/download/v1.1.7/mainnet.zip"
2+
TESTNET_FILE_URL="https://github.com/binance-chain/bsc/releases/download/v1.1.7/testnet.zip"

.github/workflows/pre-release.yml

+105
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,19 @@ jobs:
4545
- name: Build Binary for ${{matrix.os}}
4646
run: make geth
4747

48+
# ==============================
49+
# Cross Compile for ARM
50+
# ==============================
51+
52+
- name: Build Binary for ARM
53+
if: matrix.os == 'ubuntu-18.04'
54+
env:
55+
GOPATH: /home/runner/work/woodpecker/go
56+
run: |
57+
mkdir -p $GOPATH/src/github.com/binance-chain/bsc/
58+
cp -r ./* $GOPATH/src/github.com/binance-chain/bsc/
59+
cd $GOPATH/src/github.com/binance-chain/bsc/ && make geth-linux-arm
60+
4861
# ==============================
4962
# Upload artifacts
5063
# ==============================
@@ -70,6 +83,34 @@ jobs:
7083
name: windows
7184
path: ./build/bin/geth.exe
7285

86+
- name: Upload ARM-5 Build
87+
uses: actions/upload-artifact@v2
88+
if: matrix.os == 'ubuntu-18.04'
89+
with:
90+
name: arm5
91+
path: /home/runner/work/woodpecker/go/src/github.com/binance-chain/bsc/build/bin/geth-linux-arm-5
92+
93+
- name: Upload ARM-6 Build
94+
uses: actions/upload-artifact@v2
95+
if: matrix.os == 'ubuntu-18.04'
96+
with:
97+
name: arm6
98+
path: /home/runner/work/woodpecker/go/src/github.com/binance-chain/bsc/build/bin/geth-linux-arm-6
99+
100+
- name: Upload ARM-7 Build
101+
uses: actions/upload-artifact@v2
102+
if: matrix.os == 'ubuntu-18.04'
103+
with:
104+
name: arm7
105+
path: /home/runner/work/woodpecker/go/src/github.com/binance-chain/bsc/build/bin/geth-linux-arm-7
106+
107+
- name: Upload ARM-64 Build
108+
uses: actions/upload-artifact@v2
109+
if: matrix.os == 'ubuntu-18.04'
110+
with:
111+
name: arm64
112+
path: /home/runner/work/woodpecker/go/src/github.com/binance-chain/bsc/build/bin/geth-linux-arm64
113+
73114
release:
74115
name: Release
75116
needs: build
@@ -102,6 +143,30 @@ jobs:
102143
with:
103144
name: windows
104145
path: ./windows
146+
147+
- name: Download Artifacts
148+
uses: actions/download-artifact@v2
149+
with:
150+
name: arm5
151+
path: ./arm5
152+
153+
- name: Download Artifacts
154+
uses: actions/download-artifact@v2
155+
with:
156+
name: arm6
157+
path: ./arm6
158+
159+
- name: Download Artifacts
160+
uses: actions/download-artifact@v2
161+
with:
162+
name: arm7
163+
path: ./arm7
164+
165+
- name: Download Artifacts
166+
uses: actions/download-artifact@v2
167+
with:
168+
name: arm64
169+
path: ./arm64
105170

106171
- name: Download Config File
107172
run: |
@@ -161,6 +226,46 @@ jobs:
161226
asset_path: ./windows/geth.exe
162227
asset_name: geth_windows.exe
163228
asset_content_type: application/octet-stream
229+
230+
- name: Upload Release Asset - Linux ARM 5
231+
uses: actions/upload-release-asset@v1
232+
env:
233+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
234+
with:
235+
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
236+
asset_path: ./arm5/geth-linux-arm-5
237+
asset_name: geth-linux-arm-5
238+
asset_content_type: application/octet-stream
239+
240+
- name: Upload Release Asset - Linux ARM 6
241+
uses: actions/upload-release-asset@v1
242+
env:
243+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
244+
with:
245+
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
246+
asset_path: ./arm6/geth-linux-arm-6
247+
asset_name: geth-linux-arm-6
248+
asset_content_type: application/octet-stream
249+
250+
- name: Upload Release Asset - Linux ARM 7
251+
uses: actions/upload-release-asset@v1
252+
env:
253+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
254+
with:
255+
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
256+
asset_path: ./arm7/geth-linux-arm-7
257+
asset_name: geth-linux-arm-7
258+
asset_content_type: application/octet-stream
259+
260+
- name: Upload Release Asset - Linux ARM 64
261+
uses: actions/upload-release-asset@v1
262+
env:
263+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
264+
with:
265+
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
266+
asset_path: ./arm64/geth-linux-arm64
267+
asset_name: geth-linux-arm64
268+
asset_content_type: application/octet-stream
164269

165270
- name: Upload Release Asset - MAINNET.ZIP
166271
uses: actions/upload-release-asset@v1

.github/workflows/release.yml

+105
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,19 @@ jobs:
4646
- name: Build Binary for ${{matrix.os}}
4747
run: make geth
4848

49+
# ==============================
50+
# Cross Compile for ARM
51+
# ==============================
52+
53+
- name: Build Binary for ARM
54+
if: matrix.os == 'ubuntu-18.04'
55+
env:
56+
GOPATH: /home/runner/work/woodpecker/go
57+
run: |
58+
mkdir -p $GOPATH/src/github.com/binance-chain/bsc/
59+
cp -r ./* $GOPATH/src/github.com/binance-chain/bsc/
60+
cd $GOPATH/src/github.com/binance-chain/bsc/ && make geth-linux-arm
61+
4962
# ==============================
5063
# Upload artifacts
5164
# ==============================
@@ -71,6 +84,34 @@ jobs:
7184
name: windows
7285
path: ./build/bin/geth.exe
7386

87+
- name: Upload ARM-5 Build
88+
uses: actions/upload-artifact@v2
89+
if: matrix.os == 'ubuntu-18.04'
90+
with:
91+
name: arm5
92+
path: /home/runner/work/woodpecker/go/src/github.com/binance-chain/bsc/build/bin/geth-linux-arm-5
93+
94+
- name: Upload ARM-6 Build
95+
uses: actions/upload-artifact@v2
96+
if: matrix.os == 'ubuntu-18.04'
97+
with:
98+
name: arm6
99+
path: /home/runner/work/woodpecker/go/src/github.com/binance-chain/bsc/build/bin/geth-linux-arm-6
100+
101+
- name: Upload ARM-7 Build
102+
uses: actions/upload-artifact@v2
103+
if: matrix.os == 'ubuntu-18.04'
104+
with:
105+
name: arm7
106+
path: /home/runner/work/woodpecker/go/src/github.com/binance-chain/bsc/build/bin/geth-linux-arm-7
107+
108+
- name: Upload ARM-64 Build
109+
uses: actions/upload-artifact@v2
110+
if: matrix.os == 'ubuntu-18.04'
111+
with:
112+
name: arm64
113+
path: /home/runner/work/woodpecker/go/src/github.com/binance-chain/bsc/build/bin/geth-linux-arm64
114+
74115
release:
75116
name: Release
76117
needs: build
@@ -104,6 +145,30 @@ jobs:
104145
name: windows
105146
path: ./windows
106147

148+
- name: Download Artifacts
149+
uses: actions/download-artifact@v2
150+
with:
151+
name: arm5
152+
path: ./arm5
153+
154+
- name: Download Artifacts
155+
uses: actions/download-artifact@v2
156+
with:
157+
name: arm6
158+
path: ./arm6
159+
160+
- name: Download Artifacts
161+
uses: actions/download-artifact@v2
162+
with:
163+
name: arm7
164+
path: ./arm7
165+
166+
- name: Download Artifacts
167+
uses: actions/download-artifact@v2
168+
with:
169+
name: arm64
170+
path: ./arm64
171+
107172
- name: Download Config File
108173
run: |
109174
. ./.github/release.env
@@ -171,6 +236,46 @@ jobs:
171236
asset_name: geth_windows.exe
172237
asset_content_type: application/octet-stream
173238

239+
- name: Upload Release Asset - Linux ARM 5
240+
uses: actions/upload-release-asset@v1
241+
env:
242+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
243+
with:
244+
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
245+
asset_path: ./arm5/geth-linux-arm-5
246+
asset_name: geth-linux-arm-5
247+
asset_content_type: application/octet-stream
248+
249+
- name: Upload Release Asset - Linux ARM 6
250+
uses: actions/upload-release-asset@v1
251+
env:
252+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
253+
with:
254+
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
255+
asset_path: ./arm6/geth-linux-arm-6
256+
asset_name: geth-linux-arm-6
257+
asset_content_type: application/octet-stream
258+
259+
- name: Upload Release Asset - Linux ARM 7
260+
uses: actions/upload-release-asset@v1
261+
env:
262+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
263+
with:
264+
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
265+
asset_path: ./arm7/geth-linux-arm-7
266+
asset_name: geth-linux-arm-7
267+
asset_content_type: application/octet-stream
268+
269+
- name: Upload Release Asset - Linux ARM 64
270+
uses: actions/upload-release-asset@v1
271+
env:
272+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
273+
with:
274+
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
275+
asset_path: ./arm64/geth-linux-arm64
276+
asset_name: geth-linux-arm64
277+
asset_content_type: application/octet-stream
278+
174279
- name: Upload Release Asset - MAINNET.ZIP
175280
uses: actions/upload-release-asset@v1
176281
env:

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -48,3 +48,5 @@ profile.cov
4848
/dashboard/assets/package-lock.json
4949

5050
**/yarn-error.log
51+
cmd/geth/node/
52+
cmd/geth/__debug_bin

CHANGELOG.md

+15
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,20 @@
11
# Changelog
22

3+
## v1.1.8
4+
FEATURES
5+
* [\#668](https://github.com/binance-chain/bsc/pull/668) implement State Verification && Snapshot Commit pipeline
6+
* [\#581](https://github.com/binance-chain/bsc/pull/581) implement geth native trace
7+
* [\#543](https://github.com/binance-chain/bsc/pull/543) implement offline block prune tools
8+
9+
IMPROVEMENT
10+
* [\#704](https://github.com/binance-chain/bsc/pull/704) prefetch state by applying the transactions within one block
11+
* [\#713](https://github.com/binance-chain/bsc/pull/713) add ARM binaries for release pipeline
12+
13+
BUGFIX
14+
* [\#667](https://github.com/binance-chain/bsc/pull/667) trie: reject deletions when verifying range proofs #667
15+
* [\#643](https://github.com/binance-chain/bsc/pull/643) add timeout for stopping p2p server to fix can not gracefully shutdown issue
16+
* [\#740](https://github.com/binance-chain/bsc/pull/740) update discord link which won't expire
17+
318
## v1.1.7
419

520
BUGFIX

PULL_REQUEST_TEMPLATE

-14
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,3 @@ add an example CLI or API response...
1515
Notable changes:
1616
* add each change in a bullet point here
1717
* ...
18-
19-
### Preflight checks
20-
21-
- [ ] build passed (`make build`)
22-
- [ ] tests passed (`make test`)
23-
- [ ] manual transaction test passed
24-
25-
### Already reviewed by
26-
27-
...
28-
29-
### Related issues
30-
31-
... reference related issue #'s here ...

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Binance Smart Chain starts its development based on go-ethereum fork. So you may
77
[![API Reference](
88
https://camo.githubusercontent.com/915b7be44ada53c290eb157634330494ebe3e30a/68747470733a2f2f676f646f632e6f72672f6769746875622e636f6d2f676f6c616e672f6764646f3f7374617475732e737667
99
)](https://pkg.go.dev/github.com/ethereum/go-ethereum?tab=doc)
10-
[![Discord](https://img.shields.io/badge/discord-join%20chat-blue.svg)](https://discord.gg/5Z3C3SdxDw)
10+
[![Discord](https://img.shields.io/badge/discord-join%20chat-blue.svg)](https://discord.gg/z2VpC455eU)
1111

1212
But from that baseline of EVM compatible, Binance Smart Chain introduces a system of 21 validators with Proof of Staked Authority (PoSA) consensus that can support short block time and lower fees. The most bonded validator candidates of staking will become validators and produce blocks. The double-sign detection and other slashing logic guarantee security, stability, and chain finality.
1313

@@ -203,7 +203,7 @@ from anyone on the internet, and are grateful for even the smallest of fixes!
203203

204204
If you'd like to contribute to bsc, please fork, fix, commit and send a pull request
205205
for the maintainers to review and merge into the main code base. If you wish to submit
206-
more complex changes though, please check up with the core devs first on [our discord channel](https://discord.gg/5Z3C3SdxDw)
206+
more complex changes though, please check up with the core devs first on [our discord channel](https://discord.gg/z2VpC455eU)
207207
to ensure those changes are in line with the general philosophy of the project and/or get
208208
some early feedback which can make both your efforts much lighter as well as our review
209209
and merge procedures quick and simple.

cmd/evm/disasm.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ func disasmCmd(ctx *cli.Context) error {
4646
case ctx.GlobalIsSet(InputFlag.Name):
4747
in = ctx.GlobalString(InputFlag.Name)
4848
default:
49-
return errors.New("Missing filename or --input value")
49+
return errors.New("missing filename or --input value")
5050
}
5151

5252
code := strings.TrimSpace(in)

cmd/evm/internal/t8ntool/execution.go

+7-3
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ type stEnvMarshaling struct {
8282
// Apply applies a set of transactions to a pre-state
8383
func (pre *Prestate) Apply(vmConfig vm.Config, chainConfig *params.ChainConfig,
8484
txs types.Transactions, miningReward int64,
85-
getTracerFn func(txIndex int, txHash common.Hash) (tracer vm.Tracer, err error)) (*state.StateDB, *ExecutionResult, error) {
85+
getTracerFn func(txIndex int, txHash common.Hash) (tracer vm.EVMLogger, err error)) (*state.StateDB, *ExecutionResult, error) {
8686

8787
// Capture errors for BLOCKHASH operation, if we haven't been supplied the
8888
// required blockhashes
@@ -223,7 +223,9 @@ func (pre *Prestate) Apply(vmConfig vm.Config, chainConfig *params.ChainConfig,
223223
statedb.AddBalance(pre.Env.Coinbase, minerReward)
224224
}
225225
// Commit block
226-
root, _, err := statedb.Commit(chainConfig.IsEIP158(vmContext.BlockNumber))
226+
statedb.Finalise(chainConfig.IsEIP158(vmContext.BlockNumber))
227+
statedb.AccountsIntermediateRoot()
228+
root, _, err := statedb.Commit(nil)
227229
if err != nil {
228230
fmt.Fprintf(os.Stderr, "Could not commit state: %v", err)
229231
return nil, nil, NewError(ErrorEVM, fmt.Errorf("could not commit state: %v", err))
@@ -252,7 +254,9 @@ func MakePreState(db ethdb.Database, accounts core.GenesisAlloc) *state.StateDB
252254
}
253255
}
254256
// Commit and re-open to start with a clean state.
255-
root, _, _ := statedb.Commit(false)
257+
statedb.Finalise(false)
258+
statedb.AccountsIntermediateRoot()
259+
root, _, _ := statedb.Commit(nil)
256260
statedb, _ = state.New(root, sdb, nil)
257261
return statedb
258262
}

0 commit comments

Comments
 (0)