[Upgrade] Go-Ethereum release v1.9.15#1131
Merged
ricardolyn merged 55 commits intomasterfrom Feb 19, 2021
Merged
Conversation
* accounts/abi: simplified reflection logic * accounts/abi: simplified reflection logic * accounts/abi: removed unpack * accounts/abi: removed comments * accounts/abi: removed uneccessary complications * accounts/abi: minor changes in error messages * accounts/abi: removed unnused code * accounts/abi: fixed indexed argument unpacking * accounts/abi: removed superfluous test cases This commit removes two test cases. The first one is trivially invalid as we have the same test cases as passing in packing_test.go L375. The second one passes now, because we don't need the mapArgNamesToStructFields in unpack_atomic anymore. Checking for purely underscored arg names generally should not be something we do as the abi/contract is generally out of the control of the user. * accounts/abi: removed comments, debug println * accounts/abi: added commented out code * accounts/abi: addressed comments * accounts/abi: remove unnecessary dst.CanSet check * accounts/abi: added dst.CanSet checks
* cmd/clef, signer/core: use better terminal input for passwords, make it possible to avoid boot-up warning * all: move commonly used prompter to isolated (small) package * cmd/clef: Add new --acceptWarn to clef README * cmd/clef: rename flag 'acceptWarn' to 'suppress-bootwarn' Co-authored-by: ligi <ligi@ligi.de>
* abi/bind/backends: testcase for double-lock * accounts: add blockByNumberNoLock to avoid double-lock * backend/simulated: use stateroot, not blockhash for retrieveing state Co-authored-by: Martin Holst Swende <martin@swende.se>
* trie: implement range proof with non-existent edge proof * trie: fix cornercase * trie: consider empty range * trie: add singleSide test * trie: support all-elements range proof * trie: fix typo * trie: tiny typos and formulations Co-authored-by: Péter Szilágyi <peterke@gmail.com>
This PR reimplements the light client server pool. It is also a first step to move certain logic into a new lespay package. This package will contain the implementation of the lespay token sale functions, the token buying and selling logic and other components related to peer selection/prioritization and service quality evaluation. Over the long term this package will be reusable for incentivizing future protocols. Since the LES peer logic is now based on enode.Iterator, it can now use DNS-based fallback discovery to find servers. This document describes the function of the new components: https://gist.github.com/zsfelfoldi/3c7ace895234b7b345ab4f71dab102d4
* metrics/prometheus: define type once for histograms * metrics/prometheus: test collector
…1073) * ethstats: avoid blocking chan when received invalid stats request * ethstats: minor code polishes Co-authored-by: Péter Szilágyi <peterke@gmail.com>
* trie: fix for range proof * trie: fix typo
* build: upgrade to golangci-lint v1.27.0 * build: raise lint timeout to 3 minutes
This adds a new API method on core.BlockChain to allow interrupting running data inserts, and calls the method before shutting down the downloader. The BlockChain interrupt checks are now done through a method instead of inlining the atomic load everywhere. There is no loss of efficiency from this and it makes the interrupt protocol a lot clearer because the check is defined next to the method that sets the flag.
Co-authored-by: linjing <linjingjing@baidu.com>
* trie: add hasRightElement indicator * trie: ensure the range is monotonic increasing * trie: address comment and fix lint * trie: address comment * trie: make linter happy Co-authored-by: Péter Szilágyi <peterke@gmail.com>
This PR makes use of go 1.13 error handling, wrapping errors and using errors.Is to check a wrapped root-cause. It also removes the travis builders for go 1.11 and go 1.12.
* replace gosigar with gopsutil * removed check for whether GOOS is openbsd * removed accidental import of runtime * potential fix for difference in units between gosig and gopsutil * fixed lint error * remove multiplication factor * uses cpu.ClocksPerSec as the multiplication factor * changed dependency from shirou to renaynay (#20) * updated dep * switching back from using renaynay fork to using upstream as PRs were merged on upstream * removed empty line * optimized imports * tidied go mod
* core/vm: implement EIP 2315, subroutines for the EVM * core/vm: eip 2315 - lintfix + check jump dest validity + check ret stack size constraints logger: markdown-friendly traces, validate jumpdest, more testcase, correct opcodes * core/vm: update subroutines acc to eip: disallow walk-into * core/vm/eips: gas cost changes for subroutines * core/vm: update opcodes for EIP-2315 * core/vm: define RETURNSUB as a 'jumping' operation + review concerns Co-authored-by: Martin Holst Swende <martin@swende.se>
This moves all v4 protocol definitions to a new package, p2p/discover/v4wire. The new package will be used for low-level protocol tests.
* rpc: send websocket ping when connection is idle * rpc: use non-blocking send for websocket pingReset
* core/vm: crypto/bls12381: minor code comments * crypto/bls12381: fix comment
* internal/ethapi: return revert reason for eth_call * internal/ethapi: moved revert reason logic to doCall * accounts/abi/bind/backends: added revert reason logic to simulated backend * internal/ethapi: fixed linting error * internal/ethapi: check if require reason can be unpacked * internal/ethapi: better error logic * internal/ethapi: simplify logic * internal/ethapi: return vmError() * internal/ethapi: move handling of revert out of docall * graphql: removed revert logic until spec change * rpc: internal/ethapi: added custom error types * graphql: use returndata instead of return Return() checks if there is an error. If an error is found, we return nil. For most use cases it can be beneficial to return the output even if there was an error. This code should be changed anyway once the spec supports error reasons in graphql responses * accounts/abi/bind/backends: added tests for revert reason * internal/ethapi: add errorCode to revert error * internal/ethapi: add errorCode of 3 to revertError * internal/ethapi: unified estimateGasErrors, simplified logic * internal/ethapi: unified handling of errors in DoEstimateGas * rpc: print error data field * accounts/abi/bind/backends: unify simulatedBackend and RPC * internal/ethapi: added binary data to revertError data * internal/ethapi: refactored unpacking logic into newRevertError * accounts/abi/bind/backends: fix EstimateGas * accounts, console, internal, rpc: minor error interface cleanups * Revert "accounts, console, internal, rpc: minor error interface cleanups" This reverts commit 2d3ef53c5304e429a04983210a417c1f4e0dafb7. * re-apply the good parts of 2d3ef53c53 * rpc: add test for returning server error data from client Co-authored-by: rjl493456442 <garyrong0905@gmail.com> Co-authored-by: Péter Szilágyi <peterke@gmail.com> Co-authored-by: Felix Lange <fjl@twurst.com>
params: update CHTs for 1.9.15 release
…/go-ethereum/v1.9.15-2021212113514
… genesis block: unsupported fork ordering: homesteadBlock enabled at 314, but daoForkBlock enabled at 141 by updating genesis config in TestCustomGenesisUpgradeWithPrivacyEnhancementsBlock
…/go-ethereum/v1.9.15-2021212113514
Base automatically changed from
upgrade/go-ethereum/v1.9.14-2021211111542
to
master
February 15, 2021 16:47
Contributor
Author
|
Tested inserting several thousands of Tx to the network (with 1 node down) and then check if while catching up the chain, the shutdown worked fine and quick as expected on ethereum/go-ethereum#21114. Seems ok. |
nmvalera
reviewed
Feb 17, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TODO
Plan & Analyse
As you review, list extra changes and/or tests to be implemented to ensure compatibility with GoQuorum specific features.
Build & Test
masterinto this branchExtra Changes & Tests
Fatal: Failed to write genesis block: unsupported fork ordering: homesteadBlock enabled at 314, but daoForkBlock enabled at 141by updating genesis config inTestCustomGenesisUpgradeWithPrivacyEnhancementsBlockGo-Ethereum Release: Dextro Heat Sink (v1.9.15)
Release notes
Geth v1.9.15 is a maintenance release containing bug fixes as well as implementations of all EIPs currently scheduled for the upcoming Berlin fork. A temporary test network for these EIPs has also been launched at https://yolonet.xyz/ and can be joined via Geth with
--yolov1flag.The minimum Go version required to build
go-ethereumis now Go 1.13.The
eth_call,eth_estimateGasandeth_sendTransactionRPC methods now return the revert reason as a JSON-RPC error when the contract executes REVERT. The returned error includes the decoded reason string in the error message, and also makes the raw REVERT data available in the error's"data"field:Other improvements and fixes in this release:
gosigarlibrary have been replaced bygopsutil. This restores building Geth ondarwinwithout cgo and makes automatic database cache size selection work on OpenBSD (#21041).puppethfaucet's tweet retrieval endpoint (#21172).The following core EIPs are implemented in this release:
Please note that the EIP implementations are not yet scheduled to activate and will receive further testing and development before the fork.
For a full rundown of the changes please consult the Geth 1.9.15 release milestone.
As with all our previous releases, you can find the:
ethereum/client-go.Codebase changes assessment
Legend
File Stats: (A) Added, (M) Modified and (R) Removed
Line Stats: (A) Added and (R) Removed
Assessment:
40 Pull Requests
M/A/R
(files changed)
A/R
(lines changed)
Corrections to logged error messages.cmd/clef(1)cmd/puppeth(1)cmd/clef/main.go(4)cmd/puppeth/wizard_genesis.go(4)accounts/abi: simplify reflection logicaccounts/abi(4)accounts/abi/argument.go(276)accounts/abi/reflect.go(146)accounts/abi/unpack_test.go(16)accounts/abi/event_test.go(8)console: fix unlockAccount argument count checkconsole(1)console/bridge.go(4)cmd/clef, signer/core: password input fixescmd/geth(3)console(3)cmd/clef(2)cmd/devp2p(1)cmd/ethkey(1)cmd/wnode(1)console/prompt(1)signer/core(1)console/console.go(62)cmd/clef/main.go(44)signer/core/cliui.go(26)console/bridge.go(18)console/console_test.go(18)accounts: add blockByNumberNoLock() to avoid double-lockaccounts/abi/bind/backends(2)accounts/abi/bind/backends/simulated.go(20)accounts/abi/bind/backends/simulated_test.go(20)whisper : cname of package go-ethereumwhisper/shhclient(1)whisper/shhclient/client.go(4)trie: improve range prooftrie(2)go.sum(1)trie/proof_test.go(736)trie/proof.go(426)go.sum(4)les, les/lespay: implement new server poolles(14)les/lespay/client(7)les/utils(3)p2p/nodestate(2)params(1)cmd/utils(1)core/forkid(1)eth(1)les/serverpool.go(2454)p2p/nodestate/nodestate.go(1760)p2p/nodestate/nodestate_test.go(778)les/serverpool_test.go(704)les/lespay/client/wrsiterator.go(256)miner: replace use of 'self' as receiver nameminer(1)miner/miner.go(8)all: fix typos in commentscore/state/snapshot(5)core(4)cmd/clef(3)cmd/puppeth(2)core/vm(2)accounts/scwallet(2)accounts/abi/bind(2)core/rawdb(1)accounts/abi/bind/backends(1)accounts/abi(1)accounts/external(1)accounts(1)consensus/misc(1)cmd/clef/docs(1)cmd/geth(1)consensus/clique(1)eth/downloader(1)core/state/snapshot/iterator.go(16)cmd/clef/README.md(8)cmd/clef/intapi_changelog.md(8)cmd/puppeth/module_dashboard.go(8)eth/downloader/downloader.go(8)consensus/clique: remove redundant pair of parenthesesconsensus/clique(1)consensus/clique/api.go(4)core/vm: improve jumpdest lookupcore/vm(1)core/vm/contract.go(30)consensus/ethash: fix flaky test by reading seal resultsconsensus/ethash(1)consensus/ethash/sealer_test.go(16)cmd/utils: fix default DNS discovery configurationcmd/utils(1)cmd/utils/flags.go(4)metrics/prometheus: define TYPE once, add testsmetrics/prometheus(2)metrics/prometheus/collector_test.go(220)metrics/prometheus/collector.go(22)ethdb/leveldb: use timer instead of time.Afterethdb/leveldb(1)ethdb/leveldb/leveldb.go(12)ethstats: avoid blocking chan when received invalid stats requestethstats(1)ethstats/ethstats.go(18)trie: fix for range prooftrie(2)trie/proof.go(146)trie/proof_test.go(112)build: upgrade to golangci lint v1.27.0build(2).golangci.yml(1)build/checksums.txt(66).golangci.yml(4)build/ci.go(4)eth: interrupt chain insertion on shutdownlight(1)core(1)eth(1)core/blockchain.go(80)light/lightchain.go(24)eth/sync.go(16)unified clique variable nameconsensus/clique(1)consensus/clique/clique.go(12)trie: ensure the range is monotonic increasingtrie(2)trie/proof.go(274)trie/proof_test.go(236)eth/downloader: more context in errorseth/downloader(3).travis.yml(1)eth/downloader/downloader.go(70)eth/downloader/downloader_test.go(54).travis.yml(40)eth/downloader/queue.go(28)metrics: replace gosigar with gopsutilmetrics(1)cmd/geth(1)go.mod(1)go.sum(1)cmd/geth/main.go(54)metrics/cpu_enabled.go(40)go.sum(8)go.mod(4)EIP-2315: JUMPSUB for the EVMcore/vm(12)eth/tracers(2)core/vm/runtime(1)core/vm/runtime/runtime_test.go(498)core/vm/logger.go(200)core/vm/opcodes.go(68)core/vm/eips.go(66)core/vm/instructions.go(66)p2p/discover: move discv4 encoding to new 'v4wire' packagep2p/discover(4)p2p/discover/v4wire(2)p2p/discover/v4_udp.go(912)p2p/discover/v4wire/v4wire.go(600)p2p/discover/v4_udp_test.go(474)p2p/discover/v4wire/v4wire_test.go(304)p2p/discover/v4_lookup_test.go(30)rpc: send websocket ping when connection is idlerpc(1)rpc/websocket.go(132)console: handle undefined + null in console funcsconsole(2)console/bridge_test.go(96)console/bridge.go(36)core: collect NewTxsEvent items without holding reorg lockcore(1)core/tx_pool.go(30)core/vm, crypto/bls12381, params: add bls12-381 elliptic curve precompilescore/vm/testdata/precompiles(25)crypto/bls12381(3)core/vm(2)crypto/bls12381/arithmetic_x86.s(4300)core/vm/contracts_test.go(1258)core/vm/testdata/precompiles/blsG1Add.json(1252)core/vm/testdata/precompiles/blsG1Mul.json(1252)core/vm/testdata/precompiles/blsG2Add.json(1252)core,params,puppeth: inital support for yolo-v1 testnetcore/vm(5)cmd/geth(4)core(2)params(2)cmd/puppeth(1)cmd/utils(1)tests(1)params/config.go(154)cmd/utils/flags.go(44)core/genesis.go(26)tests/init.go(24)core/vm/jump_table.go(18)cmd/geth: fix the fork orders for DAO testscmd/geth(2)cmd/geth/dao_test.go(12)cmd/geth/genesis_test.go(4)acounts/keystore, cmd/faucet: fix faucet double import, fix twitter urlaccounts/keystore(1)cmd/faucet(1)cmd/faucet/faucet.go(18)accounts/keystore/keystore.go(16)cmd/faucet: delete old keystore when importing new faucet keyaccounts/keystore(1)cmd/faucet(1)accounts/keystore/keystore.go(24)cmd/faucet/faucet.go(12)go.mod: upgrade go-duktape to hide unused function warninggo.mod(1)go.sum(1)go.sum(8)go.mod(4)Fix typo on node.Config toml tagsnode(1)node/config.go(4)core/vm: crypt/bls12381: fixed comments in blscrypto/bls12381(2)core/vm(1)core/vm/contracts.go(4)crypto/bls12381/fp2.go(4)crypto/bls12381/g2.go(4)core: fix typo in commentscore/forkid(1)core/forkid/forkid.go(4)internal/ethapi: return revert reason for eth_callrpc(7)accounts/abi/bind/backends(2)console(1)graphql(1)internal/ethapi(1)accounts/abi/bind/backends/simulated_test.go(448)internal/ethapi/api.go(134)accounts/abi/bind/backends/simulated.go(106)console/bridge.go(62)rpc/client_test.go(54)params: update CHTs for 1.9.15 releaseparams(1)params/config.go(64)218 Changed files
crypto/bls12381/arithmetic_x86.scrypto/bls12381/fp_test.goles/serverpool.gocore/vm/contracts_test.go#21018
core/vm/testdata/precompiles/blsG2Add.jsoncore/vm/testdata/precompiles/blsG1Add.jsoncore/vm/testdata/precompiles/blsG2Mul.jsoncore/vm/testdata/precompiles/blsG1Mul.jsoncore/vm/testdata/precompiles/blsG1MultiExp.jsoncore/vm/testdata/precompiles/blsG2MultiExp.jsoncore/vm/testdata/precompiles/blsMapG2.jsoncore/vm/testdata/precompiles/blsMapG1.jsoncore/vm/testdata/precompiles/blsPairing.jsoncrypto/bls12381/arithmetic_fallback.gocrypto/bls12381/g2.gocore/vm/contracts.go#21182
#21154
#21018
crypto/bls12381/g1.goles/serverpool_test.gocrypto/bls12381/fp6.gocrypto/bls12381/field_element.gocrypto/bls12381/g2_test.gocrypto/bls12381/g1_test.gocrypto/bls12381/pairing.gocrypto/bls12381/fp12.gocrypto/bls12381/fp2.gocrypto/bls12381/field_element_test.gocore/vm/runtime/runtime_test.goaccounts/abi/bind/backends/simulated_test.go#21083
crypto/bls12381/pairing_test.gocrypto/bls12381/bls12_381.gocrypto/bls12381/isogeny.gocrypto/bls12381/fp.gocrypto/bls12381/swu.goaccounts/abi/argument.goles/lespay/client/wrsiterator.goles/lespay/client/queueiterator.gocrypto/bls12381/gt.goles/lespay/client/fillset_test.gocore/vm/testdata/precompiles/bn256ScalarMul.jsonles/lespay/client/fillset.goles/lespay/client/queueiterator_test.gocore/vm/testdata/precompiles/modexp.jsonles/lespay/client/wrsiterator_test.gocore/vm/logger.gocore/vm/testdata/precompiles/bn256Add.jsoncore/vm/testdata/precompiles/bn256Pairing.jsoncrypto/bls12381/arithmetic_decl.goaccounts/abi/reflect.gointernal/ethapi/api.goaccounts/abi/bind/backends/simulated.go#20983
#21083
console/bridge.go#20960
#21160
#21083
les/client.goconsole/bridge_test.gocrypto/bls12381/utils.gocmd/utils/flags.go#20758
#21154
core/blockchain.go#21114
core/vm/testdata/precompiles/fail-blsPairing.jsoneth/downloader/downloader.go#21067
les/fetcher.goles/retrieve.gocore/vm/opcodes.gobuild/checksums.txtcore/vm/instructions.gocore/vm/eips.gocore/vm/testdata/precompiles/fail-blsG2Add.jsoncmd/geth/main.go#20960
#21154
core/vm/testdata/precompiles/fail-blsG1Add.jsoncore/vm/testdata/precompiles/fail-blsG1MultiExp.jsoncore/vm/testdata/precompiles/fail-blsG2MultiExp.jsoncore/vm/testdata/precompiles/blake2F.jsoncore/vm/testdata/precompiles/fail-blsG1Mul.jsoncore/vm/testdata/precompiles/ecRecover.jsoncore/vm/testdata/precompiles/fail-blsG2Mul.jsonconsole/console.gocore/vm/instructions_test.goeth/downloader/downloader_test.gocrypto/bls12381/arithmetic_x86_adx.gocrypto/bls12381/arithmetic_x86_noadx.gocmd/clef/main.go#20960
core/vm/contract.go#20619
core/vm/testdata/precompiles/fail-blsMapG1.jsoncore/vm/testdata/precompiles/fail-blake2f.jsoncore/vm/testdata/precompiles/fail-blsMapG2.jsonles/lespay/client/valuetracker.go.travis.ymlcore/forkid/forkid.go#21181
core/vm/stack.gocore/vm/interpreter.go#21154
core/tx_pool.go#21145
accounts/keystore/keystore.go#21173
cmd/faucet/faucet.go#21173
core/vm/gen_structlog.goeth/downloader/queue.gocrypto/bls12381/bls12_381_test.gocore/genesis.goles/enr_entry.goles/distributor.goles/client_handler.goeth/sync.goles/utils/expiredvalue.gocore/vm/jump_table.goconsole/console_test.goethstats/ethstats.goconsensus/ethash/sealer_test.goaccounts/abi/unpack_test.gogo.sum#21041
#21168
core/state/snapshot/iterator.gocmd/wnode/main.goles/metrics.gocmd/geth/dao_test.goconsensus/clique/clique.gocmd/ethkey/utils.gocmd/geth/accountcmd.gocmd/geth/chaincmd.go#21154
cmd/puppeth/wizard_genesis.go#21154
eth/backend.gographql/graphql.goethdb/leveldb/leveldb.gocmd/clef/README.md#20960
core/vm/logger_json.goles/commons.gocore/vm/errors.gocmd/puppeth/module_dashboard.goaccounts/abi/event_test.gogo.mod#21168
internal/jsre/deps/web3.jscmd/devp2p/dnscmd.goeth/tracers/tracer_test.goeth/fetcher/tx_fetcher_test.gocmd/clef/intapi_changelog.mdeth/tracers/tracer.gocore/vm/logger_test.goles/peer.gocore/vm/evm.gocmd/clef/datatypes.mdconsensus/clique/clique_test.go.golangci.ymlcore/blockchain_test.goaccounts/scwallet/wallet.goconsole/prompt/prompter.gocore/vm/gas.goaccounts/hd_test.gobuild/ci.goles/server.goaccounts/abi/bind/template.goeth/fetcher/tx_fetcher.goaccounts/abi/type.goaccounts/abi/bind/base.gocmd/geth/genesis_test.gointernal/cmdtest/test_cmd.goles/clientpool.goconsensus/clique/api.goeth/downloader/peer.gocore/rawdb/chain_iterator.goaccounts/external/backend.gocore/state/snapshot/wipe.gocore/error.gocore/state/snapshot/difflayer.gocore/state/snapshot/iterator_fast.gocmd/puppeth/module_faucet.gocmd/geth/consolecmd.goaccounts/scwallet/hub.gocmd/geth/consolecmd_test.gocore/state/snapshot/snapshot.goles/test_helper.gocmd/clef/docs/setup.mdconsensus/misc/dao.gocore/genesis_alloc.gocmd/geth/usage.goles/protocol.gop2p/rlpx_test.gotests/init.gometrics/cpu_enabled.gorpc/server.gop2p/nodestate/nodestate_test.goparams/config.go#21154
rpc/errors.gop2p/discover/node.gotests/fuzzers/README.mdrpc/json.gop2p/discover/v4_lookup_test.gotrie/proof_test.go#21000
#21107
p2p/dnsdisc/client.gop2p/nodestate/nodestate.gometrics/prometheus/collector_test.gonode/node_test.gop2p/discover/v4_udp.gominer/miner.gorpc/client_test.gorpc/handler.gometrics/prometheus/collector.gonode/config.goparams/protocol_params.gowhisper/shhclient/client.gomobile/doc.gorpc/server_test.gosigner/core/signed_data.gotrie/database.gorpc/websocket.goparams/bootnodes.go#21154
signer/core/uiapi.gotrie/proof.go#21000
#21107
p2p/discover/v4wire/v4wire.gorpc/types.goles/utils/weighted_select.goparams/version.gotrie/committer.goparams/network_params.gop2p/discover/v4wire/v4wire_test.golog/doc.golight/lightchain.gop2p/simulations/http.goles/utils/weighted_select_test.gorpc/testservice_test.gosigner/core/cliui.golog/handler.gop2p/discover/v4_udp_test.golog/format.go