wgr523
e13265a7d7
record total minted into smart contract ( #1026 )
...
* feat: record total minted into smart contract
* feat: GetCurrentTotalMinted API
2025-06-16 02:31:33 -07:00
wgr523
6a38aa00aa
Reward float upgrade ( #940 )
...
* feat: use float type reward
* feat: add test of float reward
2025-04-16 02:03:41 -07:00
Daniel Liu
5b8c267122
trie: use trie.NewStackTrie instead of new(trie.Trie) ( #22246 )
2025-04-07 16:44:32 +08:00
benjamin202410
b8a9a8bfb1
Merge pull request #924 from XinFinOrg/update-reward-percapita
...
Update reward percapita
2025-03-28 23:52:33 -07:00
Daniel Liu
c73a0aa929
core/state: fix state iterator ( #19127 )
2025-03-28 22:34:59 +08:00
Gerui Wang
6bac06b1e7
feat: fixed reward per node (per capita)
2025-03-25 22:33:49 +08:00
Gerui Wang
84ae914350
feat: add TIPEpochHalving, better style
2025-03-25 22:16:35 +08:00
Daniel Liu
a9b9f53701
core, eth, trie: add a prefix to contract code (21080)
2025-03-24 22:31:03 +08:00
wgr523
c36e4d54c0
Upgrade reward 2.0 ( #865 )
...
* refactor: reward hook gets prepared for upgrade
* feat: new reward hook, config change, unit tests
* add missing code
* feat: filter penalty in reward. add unit test
* update constant and config
---------
Co-authored-by: liam.lai <liam.lai@us>
2025-03-02 02:44:34 -08:00
JukLee0ira
d6b136ed7c
consensus, internal, contracts: remove extra hash and string conversions ( #830 )
...
* consensus, internal: remove extra hash conversions
* contracts: remove extra string conversions
2025-02-07 13:59:07 +08:00
Daniel Liu
b6f3007af1
core: move genesis alloc types to core/types ( #29003 )
2025-01-24 16:54:12 +08:00
Daniel Liu
5b10b2441c
all: use T.TempDir to create temporary test directories ( #24633 )
2025-01-24 16:54:08 +08:00
Daniel Liu
6d17a42edb
all: replace t.Log(); t.FailNow() with t.Fatal() ( #19849 )
2025-01-24 16:18:29 +08:00
Daniel Liu
f542e463d3
accounts: implement simple checkpoint syncing ( #19543 )
2025-01-24 16:18:29 +08:00
liam.lai
77f9cc59ec
merge from dev-upgrade
2024-12-27 10:03:54 -08:00
benjamin202410
332380c889
fix only timeout round exists in next epoch ( #772 )
...
* fix only timeout round exists in next epoch
* bump version
---------
Co-authored-by: liam.lai <liam.lai@us>
2024-12-23 23:09:45 -08:00
liam.lai
00785b096f
fix tc cross epoch different masternode counts issue
2024-12-22 19:34:09 -08:00
benjamin202410
78331172f3
cherry pick vote test fix
2024-12-13 01:58:58 -08:00
benjamin202410
a8560300a4
fix vote test and optimize log ( #750 )
...
Co-authored-by: liam.lai <liam.lai@us>
2024-11-29 03:14:25 -08:00
Daniel Liu
ed242b4763
all: implement EIP-1153 transient storage ( #26003 )
2024-11-15 19:39:18 +08:00
liam.icheng.lai
59a7eb1f9f
resolve conflict from master
2024-10-30 16:47:26 -07: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
a5bc0baba9
all: fix staticcheck warning ST1019: import package twice
2024-10-28 17:45:19 +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
4709ca3f13
all: fix staticcheck warning SA1006
2024-10-28 15:13:21 +08:00
Daniel Liu
a79411fa06
all: fix staticcheck warning ST1005: incorrectly formatted error string
2024-10-24 09:48:20 +08: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
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
Liam Lai
b43bb5ed1f
api epoch
2024-10-15 19:20:13 -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
wgr523
3593abe815
feat: GetEpochNumbersBetween API ( #606 )
...
* feat: GetEpochNumbersBetween API
* style: refine GetEpochNumbersBetween API
2024-09-02 00:11:12 -07:00
JukLee0ira
2d89951e5b
all: use errrors.New instead of empty fmt.Errorf
2024-06-14 19:19:21 +08:00
JukLee0ira
0aab4ced98
common: add binary variables for system contract
2024-06-06 19:33:59 +08:00
Daniel Liu
01e1728a94
all: add support for EIP-2718, EIP-2930 transactions ( #21502 )
2024-05-14 23:15:35 +08:00
Liam
d76a573cf2
PPX-01 rename NextEpochMasterNodes to NextEpochCandidates ( #510 )
2024-03-31 07:27:13 +11:00
Banana-J
816dce9527
drop peer if received bad block data which does not include the validator field ( #494 )
...
Co-authored-by: wjrjerome <wjrjerome@babylonchain.io>
2024-03-23 09:18:21 +11:00
Wanwiset Peerapatanapokin
aaa246f60e
PDF-01 ( #397 )
...
* replace deprecated ioutil lib calls
* fix for FileInfo type required
* fix for ioutil.Discard
* fix .Discard
* fix for go-bindata generated files
2024-01-19 15:05:03 +04:00
Jianrong
8e1f71e86e
Fix the typo missied to missed
2023-12-28 23:03:53 +11:00
Jianrong
e83c0a0954
Add tests to cover the new GetMissiedRoundsInEpochByBlockNum API
2023-12-28 17:37:30 +11:00
Liam
c7a42fd7c9
resolve sync issue by passing right round number ( #384 )
2023-12-27 22:14:13 +11:00
Banana-J
e30d909643
Add config into network information API ( #381 )
2023-12-19 19:02:32 +11:00
Liam
47bfdf7635
Move masternode in v2 config ( #372 )
...
* move masternode in v2 config
* update number to meet 7 vote for current setup
* add test
* update all failed test
* fix test
* remove comment
* remove comment
* fix test
2023-11-29 11:11:58 +11:00
Liam
c215316744
Make masternode dynamic ( #356 )
...
* make masternode dynamic
* fix all the tests
* remove cmt
* fix test again
2023-11-16 23:59:19 +11:00
Liam
24d02fe2b4
check v2 switch block is epoch number ( #342 )
...
* check v2 switch block is epoch number
* revert sync pr
* add test
* make default block number valid
* fix log
* fix test
2023-10-30 19:03:34 +11:00
Liam Lai
69c38ac490
fix broken the tests and one bug
2023-08-02 09:27:46 +10:00
wgr523
d578e092cd
stop reorg at committed blocks ( #276 )
...
This PR makes committed blocks non-reorg-able inside `Blockchain` struct. This ensures V2 consensus safety property in the aspect of blockchain head: committed blocks' state will not be reorg and users will always see committed blocks (or their child blocks) as current head of the blockchain.
* stop reorg at committed blocks
* fix tests
* fix tests
2023-06-08 01:16:13 +08:00
Liam
2df16bbd37
merge waitPeriod into minePeriod ( #274 )
...
* merge waitperiod into mindePeriod
* merge waitperiod into mindePeriod
2023-05-31 23:40:50 +10:00
wgr523
cd74061ac2
Extend masternode candidate ( #261 )
...
* V2 truncate MaxMasternodes from candidates after penalty,
V1 same as before
TestUpdateMultipleMasterNodes: test V2, in snapshot we have all candidates, but at epoch switch, we pick MaxMasternodes
* code looks better
2023-05-16 21:43:56 +08:00
Liam
153f8d296d
Fix API penalty bug and add more info in api ( #262 )
...
* fix api bug
* remove cmd
2023-05-16 21:23:02 +10:00