Commit graph

13670 commits

Author SHA1 Message Date
Shivam Sharma
85cdd9d281 Initial Setup 2022-08-03 01:06:18 +05:30
SHIVAM SHARMA
65875c629d
Merge pull request #477 from maticnetwork/shivam/POS-695
Fix getTransactionReceiptsByBlock and TestGetTransactionReceiptsByBlock
2022-08-03 00:33:23 +05:30
Shivam Sharma
a69109ce5e fix : removed debug logs 2022-08-02 10:34:25 +05:30
Shivam Sharma
423734c0d4 fix : deferred close() + lint 2022-08-02 01:19:42 +05:30
Shivam Sharma
b18370be6a fix : TestGetTransactionReceiptsByBlock 2022-08-02 00:57:42 +05:30
Wany
aecdd74dc8 fix GetTransactionReceiptsByBlock bug
fix fields transactionHash
2022-07-31 16:54:13 +05:30
Jerry
7e79f82a31
Merge pull request #475 from cffls/develop
Add 'bor' user during package installation
2022-07-29 13:57:36 -07:00
Pratik Patil
b64af9b843
fixed the bug caused by fillBigInt and FillTime.Duration functions (#474) 2022-07-29 17:30:25 +05:30
Jerry
cd04702345 Add 'bor' user during package installation 2022-07-28 12:33:23 -07:00
Manav Darji
6e8428bfaa
consensus/ethhash: skip TestRemoteMultiNotifyFull in sealer test (#470)
* skip test in sealer test for ethhash consensus

* add a todo and test skip reason
2022-07-27 22:29:07 +05:30
Manav Darji
8f08503a5a
Makefile: copy bor binary to go bin (#469) 2022-07-27 22:27:26 +05:30
Pratik Patil
71980bf5b1
internal/cli: use config file for flags in new-cli, builder/files: update defaults (#457)
* updated simple.json and simple.hcl

* added annotations for developer and grpc block

* added toml tags and simple.toml file

* added support for toml config files

* updated simple files toml, hcl, json

* added config.toml in builder/files and updated bor.service

* add dumpconfig command in cli for exporting configs

* update docs

* updated .goreleaser.yml (POS-651)

* changed --config to -config

* added test config for tests and fixed lint errors

* made fields of type big.int and time.Duration private, removed merge from dumpconfig, setting up default values to the Raw fields in dumpconfig, and fixed one lint error

* fixed lint errors (strange)

* lint fix

* private no-more, using '-' in name tags to ignore

* updated name tags, made c.configFile as a stringFlag (only one config file supported) and updated the merge logic in command.go -> Run()

* fix: set method for big.Int flags, added a TODO

* handeled bigInt and timeDuration type, bug fix in config_legacy, lint fix

* updated flags, consistent across flags.go and config.go

* fixed config test and updated test hcl, json config files

* updated config legacy test

* added test to check values of cmd flags, restructured Run in command.go, linter fix

* fix linters

* lint again

* changed 2 flags and assert -> require

* changed the 2 flags back

* updated correct congig.toml path and made mainnet default

* updated config.toml with new flags

* added sample config (toml) file

* removed sample-config.toml and added it in docs/config.md

Co-authored-by: Manav Darji <manavdarji.india@gmail.com>
2022-07-27 12:28:26 +05:30
Jerry
9dcc993566
Merge pull request #467 from cffls/develop
Fix "Signer 0x... is not a part of the producer set at block xxxx"
2022-07-25 21:18:20 -07:00
Jerry
c50ff82ab1 Fix "Signer 0x... is not a part of the producer set at block xxxx"
The validator set json loaded from database will have an empty map. This change will recompute the validator map based on validator set.
2022-07-25 10:19:39 -07:00
SHIVAM SHARMA
f184772b4d
Merge pull request #456 from maticnetwork/shivam/pos-636
Cover Bor Filters with testcases
2022-07-22 15:06:57 +05:30
Sylvain Laurent
dbf08033ee
typo: README (#463) 2022-07-22 11:36:41 +05:30
Jerry
9119b4b483
Merge pull request #462 from cffls/develop
Remove 'edit' from github CI workflow
2022-07-21 22:23:31 -07:00
Jerry
4089c24ae2 Remove 'edit' from github CI workflow 2022-07-21 09:30:34 -07:00
Shivam Sharma
68f440a35f fix : integration test package 2022-07-20 16:58:40 +05:30
Shivam Sharma
4e189689b0 add : mock database in eth/filters 2022-07-19 17:21:11 +05:30
Manav Darji
bf60c6ce06
consensus/bor: add mock heimdall rest-server, tests for timeout and cancellation (#458)
* add: mock heimdall rest-server, tests for timeout and cancellation

* fix: use mux for route handling
2022-07-19 16:22:41 +05:30
Shivam Sharma
58ef6fdbb7 fix : lint 2022-07-19 14:39:26 +05:30
Shivam Sharma
8a6c16dcde add : bor_filter_test.go + mock backend 2022-07-19 14:07:19 +05:30
Manav Darji
b382111b87
github: add new issue templates (#455)
* add: new issue templates

* github: add version commands and file paths
2022-07-18 20:09:15 +05:30
Shivam Sharma
43b18b7038 chg : moved TestBorFilters to tests/bor 2022-07-18 13:43:36 +05:30
Shivam Sharma
9aad8bf928 fix : remove temp dir 2022-07-15 13:12:39 +05:30
Shivam Sharma
73054f8608 Merge branch 'develop' of https://github.com/maticnetwork/bor into shivam/pos-636 2022-07-15 12:05:13 +05:30
Manav Darji
c44693706a
RFC35/Common Ancestor: Modifying the forkchoice rule (#425)
* initial

* update

* fix: add validator to NewBlockchain function calls

* handle past chain reorg

* fix: only check with last checkpoint

* rm logs

* add: handle future chain import case

* fix: handle single block case

* add unit tests for past and future chain

* modularise forker tests

* minor fixes

* add: overlapping chain test case, minor fixes

* minor fixes

* add: isolated unit test for IsValidChain

* add more test case for IsValidChain

* fix: use index for header time

* add: fetch last N checkpoints in first run

* fix: change checkpoint count to int64

* fix: handle edge case

* fix: handle no checkpoint case separately

* fix: consider offset for future chain calculation

* re-write test case for split chain

* fix: typo

* add: split chain properties test

* separate reorg checks, validate chain before inserting

* fix: handle err incase of invalid chain

* fix: use error from whitelist service

* split chain property tests

* remove duplicate test cases

* cleanup

* clean up

* fix linters

* fix: fetch checkpoint count bug, add tests

* fix more linters

* fix: handle nil chain validator in downloader

* fix: mock bor tests

Co-authored-by: Evgeny Danienko <6655321@bk.ru>
2022-07-15 10:37:35 +05:30
Pratik Patil
3df1d6f017
Change diverged flags back to Geth's convention (POS-602) (#451)
* changed name -> identity

* changed no-snapshot -> snapchot=true/false

* changed jsonrpc.corsdomain -> http.corsdomain

* changed jsonrpc.vhosts -> http.vhosts

* changed http/ws.modules to http/ws.api

* updated readme

* updated config_test

* make docs

* handelling string array flag, overwrite insted of append

* added 'Default' to SliceStringFlag

* added separate flags for corsdomain and vhosts for http, ws, graphql

* modified tests
2022-07-14 22:36:18 +05:30
Arpit Temani
7b25997830
Reciept e2e test (#431)
* initial

* fixed tests

* eip155 tests

* progress

* fix

* fix TestFetchStateSyncEvents*

* debug

* fixed with updated list of validators

* fix

* a bit more stable

* optimize allocations

* linters

* fix vals copy

* a bit of refactoring

* update TestGetTransactionReceiptsByBlock

* remove logs from TestGetTransactionReceiptsByBlock in favour of checks

* comments

* Linters

* linters

* fixes after merge

* fixes after merge

* fixes after merge

* fixes after merge

* fail fast

Co-authored-by: Evgeny Danienko <6655321@bk.ru>
2022-07-14 19:28:56 +03:00
Shivam Sharma
0610c6a692 chg : use memory db 2022-07-14 18:28:21 +05:30
Shivam Sharma
e47a2df17b fix : lint 2022-07-14 17:49:55 +05:30
Shivam Sharma
3811496280 fix : remove debug logs 2022-07-14 17:41:38 +05:30
Shivam Sharma
e670a8a0a1 add : bor_filter_test 2022-07-14 17:39:29 +05:30
SHIVAM SHARMA
1147994c65
Added valSet testcases (#452)
* Added valSet testcases

* Added Negative Assertions

* Minor Changes

* Added varying valset length

* Minor changes

* Linting
2022-07-13 12:21:29 +03:00
Evgeny Danilenko
3c42bfc633
add context to Fetch* methods (#445)
* add context

* fix mocks

* fixes after CR

* fixes

* fix

* Linters
2022-07-13 09:07:32 +03:00
marcello33
c3d62b8ea1
Merge pull request #436 from maticnetwork/mardizzone/pos-398
new: dev: pos-398 restore geth tests
2022-07-12 19:53:15 +02:00
Marcello Ardizzone
2a1a7d1b18 new: dev: pos-398 remove duplicate git submodule 2022-07-12 17:37:44 +02:00
Marcello Ardizzone
752878d3c2 new: dev: pos-398 update testdata and skip last failing tests 2022-07-12 14:29:56 +02:00
Marcello Ardizzone
a76923cb8a new: dev: pos-398 restore legacy tests 2022-07-12 14:22:18 +02:00
Marcello Ardizzone
01bebeb22e new: dev: pos-398 remove merge error check on state tests 2022-07-12 11:55:47 +02:00
Marcello Ardizzone
56eefc6a0b new: dev: pos-398 restore old testing way 2022-07-12 11:53:30 +02:00
Evgeny Danilenko
04e90e2426
internal/cli: update grpc/protobuf dependency (#449)
* update grpc_conn

* fix

* remove more deps from deprecated library

Co-authored-by: Manav Darji <manavdarji.india@gmail.com>
2022-07-11 19:09:49 +03:00
Marcello Ardizzone
5265da30b8 new: dev: pos-398 update retesteth readme 2022-07-07 12:14:55 +02:00
Marcello Ardizzone
cd366c64d8 new: dev: pos-398 move testdata to last stable release via tag v10.4 2022-07-07 11:12:57 +02:00
Marcello Ardizzone
f0d85e3703 new: dev: pos-398 remove unused bor tests derived from geth 2022-07-07 10:49:30 +02:00
Marcello Ardizzone
de1330aae6 new: dev: pos-398 comment for jira issue 2022-07-07 10:44:52 +02:00
Marcello Ardizzone
75d5646ef2 new: dev: pos-398 skipLoad stChangedEIP150 2022-07-07 10:08:39 +02:00
Marcello Ardizzone
56a5f4f67b new: dev: pos-398 lazy fix to ignore filing tests and skip the merge fork 2022-07-07 09:38:38 +02:00
Marcello Ardizzone
d2d4d1bf62 new: dev: pos-398 update testdata 2022-07-06 16:50:31 +02:00