Commit graph

13365 commits

Author SHA1 Message Date
Daniel Liu
fbecb8c5a5 all: fix staticcheck warning ST1006: don't use generic name self
The name of a method’s receiver should be a reflection of its identity;
often a one or two letter abbreviation of its type suffices (such as
“c” or “cl” for “Client”). Don’t use generic names such as “me”, “this”
or “self”, identifiers typical of object-oriented languages that place
more emphasis on methods as opposed to functions. The name need not be
as descriptive as that of a method argument, as its role is obvious and
serves no documentary purpose. It can be very short as it will appear
on almost every line of every method of the type; familiarity admits
brevity. Be consistent, too: if you call the receiver “c” in one method,
don’t call it “cl” in another.
2024-10-25 21:30:54 +08:00
Daniel Liu
acb973ab97
Merge pull request #695 from gzliudan/fix-sa1012
fix staticcheck warning SA1012: pass nil Context to function
2024-10-25 19:34:09 +08:00
Daniel Liu
dd6822bc3c internal/ethapi, contracts/trc21issuer: fix staticcheck warning SA1012: pass nil Context 2024-10-25 18:29:08 +08:00
Daniel Liu
b68b9c64ea
Merge pull request #685 from gzliudan/emptyroot
all: use unified emptyRootHash and emptyCodeHash
2024-10-25 15:28:51 +08:00
Daniel Liu
87a6b5f4c3
Merge pull request #689 from gzliudan/fix-st1005
all: fix staticcheck warning ST1005
2024-10-25 15:28:07 +08:00
Daniel Liu
bd4bb14b5e
Merge pull request #692 from gzliudan/fix-sa4006
all: fix staticcheck warning SA4006: never used value
2024-10-25 15:26:38 +08:00
Daniel Liu
739b4d7c60
Merge pull request #690 from gzliudan/fix-s1039
all: fix staticcheck warning S1039: unnecessary use of fmt.Sprintf
2024-10-25 15:25:56 +08:00
Daniel Liu
b9101e635d
Merge pull request #691 from gzliudan/fix-st1017
metrics: fix staticcheck warning ST1017: don't use yoda conditions
2024-10-25 15:25:29 +08:00
Daniel Liu
e9df8a11f0
Merge pull request #693 from gzliudan/rpc-peerinfo
fix staticcheck warning SA1029: inappropriate key in call to context.WithValue
2024-10-25 15:24:58 +08:00
Daniel Liu
48b1688e84 p2p/simulations: fix staticcheck warning SA1029 2024-10-25 12:32:32 +08:00
Daniel Liu
2844dbc5a9 rpc: fix staticcheck warning SA1029 by add PeerInfo (#24255) 2024-10-25 12:32:13 +08:00
Daniel Liu
c6e4e880ea all: fix staticcheck warning SA4006: never used value 2024-10-24 17:37:19 +08:00
Daniel Liu
3409ada149 metrics: fix staticcheck warning ST1017: don't use yoda conditions 2024-10-24 16:07:11 +08:00
Daniel Liu
f79763ca88 all: fix staticcheck warning S1039: unnecessary use of fmt.Sprintf 2024-10-24 12:49:37 +08:00
Daniel Liu
a79411fa06 all: fix staticcheck warning ST1005: incorrectly formatted error string 2024-10-24 09:48:20 +08:00
Daniel Liu
464a89074b all: use unified emptyRootHash and emptyCodeHash (#26718) 2024-10-21 17:55:16 +08:00
Liam
09fe4ec646
Merge pull request #680 from XinFinOrg/mainnet-hot-fix-v2.2.0-api-epoch
Mainnet v2.3.0 merge hot fix branch and new epoch api
2024-10-21 00:00:14 -07:00
benjamin202410
042c02ba8c
add last block number for epoch api (#681)
Co-authored-by: Liam Lai <liam@home>
2024-10-20 23:43:23 -07:00
Daniel Liu
e52b8a2de2
Merge pull request #649 from gzliudan/rm-block-hash
remove block hash from statedb
2024-10-18 10:48:34 +08:00
Liam Lai
3dac4dc014 reduce to 20s 2024-10-17 18:59:38 -07:00
Daniel Liu
8c077345d0 all: removed blockhash from statedb (#23126) 2024-10-18 09:24:52 +08:00
Liam Lai
22fc7d0710 fix conflict 2024-10-16 22:42:53 -07:00
Daniel Liu
1c84a31bb6 core/vm: deepcopy jumptable when enabling extra eips (#26137) 2024-10-17 11:23:04 +08:00
Daniel Liu
4482ea4d84 core/vm: fix docstrings 2024-10-17 11:23:04 +08:00
Daniel Liu
480adaf960 core/vm: minor trivial clean up (#25880) 2024-10-17 11:23:04 +08:00
Daniel Liu
69cb57a0f4 core/vm: not deep copy return data slice upon call completion (#25183) 2024-10-17 11:23:04 +08:00
Daniel Liu
ee5dd8673f core/vm: remove empty lines 2024-10-17 11:23:04 +08:00
Daniel Liu
16f2aabc64 core/vm: more linters (#24783) 2024-10-17 11:23:04 +08:00
Paweł Bylica
be6631beb0 core/vm: optimize jumpdest analysis (#23500)
core/vm: optimize PUSH opcode discrimination
2024-10-17 11:23:04 +08:00
Daniel Liu
1fa9e81870 core/vm: reduce overhead in instructions-benchmark (#24860) 2024-10-17 11:23:04 +08:00
Daniel Liu
c78b9e6245 core/vm: for tracing, do not report post-op memory (#24867) 2024-10-17 11:23:04 +08:00
Daniel Liu
45c644c43d core/vm: update benchmark to use Errorf instead of Sprintf (#24845) 2024-10-17 11:23:04 +08:00
Daniel Liu
6fa968201f core/vm: fix some typos 2024-10-17 11:23:04 +08:00
Daniel Liu
224caa5a08 core/vm: avoid memory expansion check for trivial ops (#24048) 2024-10-17 11:23:04 +08:00
Daniel Liu
a401d3fd3f
Merge pull request #645 from gzliudan/eip-2565
implement eip-2565
2024-10-17 11:20:58 +08:00
Daniel Liu
532137c37b core/vm: use golang native big.Int (#26834) 2024-10-17 10:36:53 +08:00
Daniel Liu
8e15f825ce core/vm: use optimized bigint (#26021) 2024-10-17 10:36:53 +08:00
Daniel Liu
abebda601c common/math, tests/fuzzers: use big.Int clone (#26006) 2024-10-17 10:36:53 +08:00
Daniel Liu
c87b7c3135 common/math: optimized modexp (#25525) 2024-10-17 10:36:53 +08:00
Daniel Liu
b653dbc60c core/vm, protocol_params: implement eip-2565 modexp repricing (#21607) 2024-10-17 10:36:53 +08:00
Daniel Liu
a8ea86e40c
Merge pull request #644 from gzliudan/format-0x
all: change format 0x%x to %#x
2024-10-17 10:35:34 +08:00
Daniel Liu
8cf0076851
Merge pull request #675 from gzliudan/fix-issue-650
return right blockHash for eth_getLogs (#650)
2024-10-16 13:51:30 +08:00
Daniel Liu
693190e5b9 core: fix wrong blockHash for eth_getLogs (#650) 2024-10-16 11:00:58 +08:00
Liam Lai
5f1fb22e51 fix conflict 2024-10-15 19:51:57 -07:00
Liam Lai
b43bb5ed1f api epoch 2024-10-15 19:20:13 -07:00
Liam
ec92add428
Update to version 2.2.5 (#670) 2024-10-10 00:02:04 -07:00
benjamin202410
f6afd24de7
update timeout to 30s (#669) 2024-10-09 23:46:02 -07:00
benjamin202410
eb6d53adf6
Fix getCandidateStatus API (#663)
* Fix getCandidateStatus API

* sync vote message and fix test

* update function name

---------

Co-authored-by: Liam Lai <liam@home>
2024-10-09 22:05:14 -07:00
Mr.P
861c7102a2 cherry pick from #664 2024-10-09 17:08:59 +08:00
Mr.P
22c54206bd
add flag rpc-gascap and set RPCGasCap to 50M (#664)
* add gas cap flag

* default gas cap to 50m

* rpc-gascap
2024-10-09 09:28:24 +08:00