* Added script to generate config.toml fromstart.sh (#518)
* added go and bash script to get config out of start.sh and updated flagset.go
* changed 'requiredblocks' flag back to 'eth.requiredblocks'
* updated script
* changed 'requiredblocks' flag back to 'eth.requiredblocks'
* updated tests, and removed requiredblocks from json and hcl
* addressed comments
* internal/cli/server: fix flag behaviour (#529)
* remove setting maxpeers to 0 for nodiscover flag
* set default prometheus and open-collector endpoint
* skip building grpc address from pprof address and port
* fix: linters
* fix and improve tests
* use loopback address for prometheus and open-collector endpoint
* add logs for prometheus and open-collector setup
* updated the script to handle prometheus-addr
* updated builder/files/config.toml
Co-authored-by: Pratik Patil <pratikspatil024@gmail.com>
Co-authored-by: Manav Darji <manavdarji.india@gmail.com>
* 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>
* merge geth v1.10.15
* fix: Removed FastSync from cli server
* fix: TestHeadersRLPStorage
* Added t.skip(ETH2 in bor)
* fix: flow in create consensus engine
* bumped version
* Fix typo
* increase block time
* remove file
* bumped version
* merge gethv1.10.17
* bumped version
* fix failing tests
* Bump Go version to v1.18 (#368)
* Bump Go version to v1.18.1
* Build using netgo tag
This will create a static build using Go native networking stack.
Checked and it works stable for all archs and distros.
* Fix meta
* initial implementation for common ancestor approach
* extract whitelist interface
* fix types
* fix tests and format
* add unit tests for IsValidChain function
* more tests
* wip
* test ErrCheckpointMismatch
* minor fixes
* fix test
* dont panic
* fmt
* Limit state sync by gas
* Added logging for state-sync total gas usage
* Added number of event-records in log
* Minor Changes
* Minor Fix
* Adding individual gasUsed
* Minor Fix
* fix: return value for no remote block
* handle all errors
* modularise fake chain validator in downloader
* add more tests
* fix tests
* Modifying miner.recommit flag and its adjustment function. (#370)
* changed min/max/current recommit values
* Remove Hardcoded min/max
* Code Sanitization
* Skipping tests for constant recommit interval
* Adding default miner.recommit value
* Minor Change
* Increased default value of rpc.txfeecap to 5
* add debug rpc endpoints for checkpoint whitelist service
* minor fixes and enhancements
* avoid capping warnings for gas set by internal system transactions
* use typed mocks
* fix
* fix
* fix
* fix close
* fix
* Create stale.yml
* Fix bor consensus checkpoint bug
Co-authored-by: Arpit Temani <temaniarpit27@gmail.com>
Co-authored-by: Shivam Sharma <shivam691999@gmail.com>
Co-authored-by: Manav Darji <manavdarji.india@gmail.com>
Co-authored-by: Sandeep Sreenath <sandeep.sreenath@gmail.com>
Co-authored-by: Victor Castell <victor@victorcastell.com>
Co-authored-by: Ferran <ferranbt@protonmail.com>
Co-authored-by: Krishna Upadhyaya <krishnau1604@gmail.com>
Co-authored-by: Karlo <karlonovak@gmail.com>
Co-authored-by: Sandeep Sreenath <ssandeep@users.noreply.github.com>
Co-authored-by: Jerry <jerrycgh@gmail.com>
* Limit state sync by gas
* Added logging for state-sync total gas usage
* Added number of event-records in log
* Minor Changes
* Minor Fix
* Adding individual gasUsed
* Minor Fix
* it works
* fix tests
* log wiggle and delay with block number
* log delays as numbers
* linters
* fix tests
* restore linters for the project
* fix linters
* fix
* fix
* fix
* linters
* generation
* fix tests
* remove heimdall wrapper response
* linters
* remove possible collisions
* remove possible collisions
* remove possible collisions
* tests for unique address generation
* generalize set
* bor miner tests got restored
* fixes after CR
* final step and mining test
* fix
* fix e2e
* more tests for Heimdall requests
* fix linters
Co-authored-by: Ferran <ferranbt@protonmail.com>
Co-authored-by: Shivam Sharma <shivam691999@gmail.com>
* bad block tracing
* Add debug env framework
* add implementation of custom block tracing
* add few comments
* use tar name fn
* wip: add unit tests for block tracing
* complete test for block tracer
* fix: close grpc server
* refactor cli tests
* fix: change condition for parsing args
* Fix port binding for test server
* add helper for creating and closing mock server for tests
* consume mock server in tests
* fixes due to geth merge
* fix: handle port selection for http server
* update help and markdown for debug command
* update docs
* update debug synopsis
* fix: use chunked encoder to handle large data over grpc
* fix prints
* lint
* rm unused function, rename fn to TraceBorBlock
Co-authored-by: Ferran Borreguero <ferranbt@protonmail.com>
This change will fix two issues:
1. When CLI sets a flag to an empty value in Go, e.g. 0 as to Uint64, the flag will be skipped and never set correctly. This problem could be solved by using option "WithOverwriteWithEmptyValue" when merge two configs.
2. The default non-empty value in server config will be overwritten to an empty value after flag initialization. This problem is solved by explicitly providing default value to all flags that have a default value option.