Commit graph

12016 commits

Author SHA1 Message Date
Daniel Liu
af40f2e194 eth/downloader: fix staticcheck warning S1033: unnecessary guard for delete 2024-10-31 21:46:27 +08:00
Daniel Liu
003af00b25
Merge pull request #723 from gzliudan/fix-s1006
core: fix staticcheck warning S1006: use for {} for infinite loops
2024-10-31 19:36:14 +08:00
Daniel Liu
b7154dd450 core: fix staticcheck warning S1006: use for {} for infinite loops 2024-10-31 16:49:56 +08:00
Daniel Liu
56a15b5844
Merge pull request #708 from gzliudan/s1008
XDCxlending: fix staticcheck warning S1008: simplify returning boolean expression
2024-10-31 11:19:36 +08:00
Daniel Liu
2db2f9d1f7 XDCxlending: fix staticcheck warning S1008: simplify returning boolean expression 2024-10-31 11:14:01 +08:00
Daniel Liu
a8f8a7abd3
Merge pull request #707 from gzliudan/fix-sa1015
metrics/influxdb: fix staticcheck warning SA1015: replace time.Tick with time.NewTicker
2024-10-31 11:13:08 +08:00
Daniel Liu
b9323b73e0 metrics/influxdb: fix staticcheck warning SA1015: replace time.Tick with time.NewTicker 2024-10-31 11:01:45 +08:00
Daniel Liu
40ae9e3ffb
Merge pull request #706 from gzliudan/fix-s1024
all: fix staticcheck warning S1024: not use x.Sub(time.Now())
2024-10-31 10:59:52 +08:00
Daniel Liu
edce9ccb27 all: fix staticcheck warning S1024: not use x.Sub(time.Now()) 2024-10-31 10:49:44 +08:00
Daniel Liu
f3787f5000
Merge pull request #705 from gzliudan/fix-sa2002
all: fix staticcheck warning SA2002: must call T.Fatalf in same goroutine
2024-10-31 10:48:49 +08:00
Daniel Liu
11285be830 all: fix staticcheck warning SA2002: must call T.Fatalf in same goroutine 2024-10-31 10:38:38 +08:00
Daniel Liu
52dd69ecdb
Merge pull request #704 from gzliudan/fix-sa5001
core, XDCxlending/lendingstate: fix staticcheck warning SA5001
2024-10-31 10:37:42 +08:00
Daniel Liu
6b6f0bd891 core, XDCxlending/lendingstate: fix staticcheck warning SA5001: must check error before rpcClient.Close() 2024-10-31 10:28:21 +08:00
Daniel Liu
84db209a66
Merge pull request #703 from gzliudan/fix-sa4003
fix: staticcheck warning SA4003: every value of uint64 >= 0
2024-10-31 10:27:03 +08:00
Daniel Liu
f9960875cc fix: staticcheck warning SA4003: every value of uint64 >= 0 2024-10-31 10:17:30 +08:00
Daniel Liu
7b7eb91fcb
Merge pull request #700 from gzliudan/fix-sa4010
all: fix staticcheck warning SA4010: append result never used
2024-10-31 10:15:42 +08:00
Daniel Liu
a14e9416fa all: fix staticcheck warning SA4010: append result never used 2024-10-31 10:06:04 +08:00
Daniel Liu
6dbf0d26e9
Merge pull request #698 from gzliudan/fix-st1008
all: fix staticcheck warning ST1008: error should be last return value
2024-10-31 10:05:04 +08:00
Daniel Liu
c36642a0e1 all: fix staticcheck warning ST1008: error should be last return value 2024-10-31 09:51:47 +08:00
Daniel Liu
f81cb2bf55
Merge pull request #688 from gzliudan/fix-nil-deref
fix nil issues reported by nilness and staticcheck
2024-10-31 09:31:14 +08:00
Daniel Liu
60fedfed83 fix staticcheck SA5011: possible nil pointer dereference 2024-10-31 09:01:12 +08:00
Daniel Liu
5f66fb5de0 fix tautological condition: nil == nil 2024-10-31 09:01:12 +08:00
Daniel Liu
371c3b6874 fix tautological condition: non-nil != nil 2024-10-31 09:01:12 +08:00
Daniel Liu
c688f4b24c fix panic with nil value 2024-10-31 09:01:12 +08:00
Daniel Liu
2306ceafb2 fix impossible condition: nil != nil 2024-10-31 09:01:12 +08:00
Daniel Liu
6ed8d399c2 fix nil dereference in field selection 2024-10-31 09:01:12 +08:00
benjamin202410
6b6cf4b988
Merge pull request #716 from XinFinOrg/merge-master-back-to-dev-upgrade
Merge master back to dev upgrade
2024-10-30 17:02:12 -07:00
liam.icheng.lai
59a7eb1f9f resolve conflict from master 2024-10-30 16:47:26 -07:00
Daniel Liu
dd7b9b1dea
Merge pull request #715 from gzliudan/fix-sa5007
XDCxDAO: fix staticcheck warning SA5007: infinite recursive call
2024-10-30 21:16:31 +08:00
Daniel Liu
381226c506 XDCxDAO: fix staticcheck warning SA5007: infinite recursive call 2024-10-30 21:16:02 +08:00
Daniel Liu
3f0e1576ab
Merge pull request #714 from gzliudan/fix-sa6005
core: fix staticcheck warning SA6005: should use strings.EqualFold
2024-10-30 21:14:22 +08:00
Daniel Liu
212daafe17 core: fix staticcheck warning SA6005: should use strings.EqualFold 2024-10-30 21:13:58 +08:00
Daniel Liu
dc562d4ab1
Merge pull request #713 from gzliudan/fix-sa9004
compression/rle: fix staticcheck warning SA9004: only the first constant has an explicit type
2024-10-30 21:12:46 +08:00
Daniel Liu
29c9c5808a compression/rle: fix staticcheck warning SA9004: constant has no explicit type 2024-10-30 21:12:32 +08:00
Daniel Liu
8f79376ef7
Merge pull request #712 from gzliudan/fix-sa9009
crypto/bn256: fix staticcheck warning SA9009: ineffectual go compiler directive
2024-10-30 21:11:16 +08:00
Daniel Liu
95f8abb765 crypto/bn256: fix staticcheck warning SA9009: ineffectual compiler directive 2024-10-30 21:10:45 +08:00
Daniel Liu
b4fe994eff
Merge pull request #711 from gzliudan/fix-st1012
XDPoSChain, ethclient: fix staticcheck warning ST1012: rename NotFound to ErrNotFound
2024-10-30 21:07:33 +08:00
Daniel Liu
1329edfe5f XDPoSChain, ethclient: fix staticcheck warning ST1012: rename NotFound to ErrNotFound 2024-10-30 21:07:05 +08:00
Daniel Liu
95f383d586
Merge pull request #710 from gzliudan/fix-s1001
common: fix staticcheck warning S1001: replace loop with copy
2024-10-30 21:05:53 +08:00
Daniel Liu
5b0b5b52c7 common: fix staticcheck warning S1001: replace loop with copy 2024-10-30 21:05:15 +08:00
Daniel Liu
5df53e81ed
Merge pull request #709 from gzliudan/fix-s1002
core, XDCxlending/lendingstate: fix staticcheck warning S1002: omit comparison to bool constant
2024-10-30 21:03:32 +08:00
Daniel Liu
181b23a767 core, XDCxlending/lendingstate: fix staticcheck warning S1002: omit comparison to bool constant 2024-10-30 21:02:41 +08:00
benjamin202410
118ccd08d5
cherry pick epoch api from dev-upgrade (#699)
* cherry-pick-epoch-api
2024-10-29 01:36:22 -07:00
Daniel Liu
57e40f59d7
Merge pull request #701 from gzliudan/fix-st1019
all: fix staticcheck warning ST1019: import package twice
2024-10-28 18:34:29 +08:00
Daniel Liu
a5bc0baba9 all: fix staticcheck warning ST1019: import package twice 2024-10-28 17:45:19 +08:00
Daniel Liu
efe041a684
Merge pull request #697 from gzliudan/fix-s1034
XDCxDAO: fix staticcheck warning S1034: use result of type assertion to simplify cases
2024-10-28 15:17:01 +08:00
Daniel Liu
9c1492189d XDCxDAO: fix staticcheck warning S1034: use result of type assertion to simplify cases 2024-10-28 15:16:22 +08:00
wgr523
71b9005f34
feat: add api xdpos_getBlockInfoByEpochNum (#674)
* feat: add api xdpos_getBlockInfoByEpochNum

* feat: add cache round2epochBlockInfo

* fix: round2epochBlockInfo contains round now

* feat: binary search in GetBlockByEpochNumber

* fix: change some code back, refine style
2024-10-28 00:14:30 -07:00
Daniel Liu
f12e92bbc7
Merge pull request #696 from gzliudan/fix-sa1006
all: fix staticcheck warning SA1006
2024-10-28 15:14:08 +08:00
Daniel Liu
4709ca3f13 all: fix staticcheck warning SA1006 2024-10-28 15:13:21 +08:00