359 Commits
Author SHA1 Message Date
Ceyhun OnurandGitHub a6d013d4ab Coreth 0.8.16 rc2 (#216)
* Unwrap ETHChain

* hook in vm.ethConfig

* statesync for subnet-evm

* remove unused configJSON

* add err check

* add synchronization

* add default config values

* delay initialization of gossiper

* Revert "add synchronization"

This reverts commit 2e8c93e58d7853de15a21ebd1460a3cd3858a6af.

* fix test

* fix statesync code prefix issue

* fix comment

* wip

* wip2

* add coreth changes

* Merge branch 'master' into coreth-0.8.16-rc2

* updates

* remove coreth from go.mod

* fix linter

* fix

* update gas prices (?)

* fix tracer test

* move dependabot yml to upper file

* more changes ported in from coreth 0.8.16

* Update sync/README.md

Co-authored-by: Ceyhun Onur <[email protected]>

* Update sync/README.md

Co-authored-by: Ceyhun Onur <[email protected]>

* Update sync/README.md

Co-authored-by: Ceyhun Onur <[email protected]>

* Update core/rawdb/accessors_state_sync.go

* port missing file from coreth

* fix-import

* subscribe before goroutine

* Rebase apply coreth diff onto statesync

* fix EOF in tests

* Nits (#265)

* Nits

* Add EIP-1559 link to readme

* Fix linting introduced by merge
2022-09-22 18:42:37 +09:00
Ceyhun OnurandGitHub 042814df00 add initial precompile configs and handle them (#226)
* add initial precompile configs and handle them

* add verify to precompile configs

* add unit tests for initial configs and verify

* add a nil check for initial fee config verification

* conditionally verify allowlist

* Update precompile/stateful_precompile_config.go

* add config test to precompile package

* add 0 test case for gas limit

* add comments for allowlist storage keys

* move allow list role to different file

* Update precompile/allow_list.go

* rename test

* Update precompile/allow_list.go

* rename test & use func to create config

* Remove unnecessary role checks

* use config constructor for precompile tests

* Update accounts/abi/bind/precompile_template.go

* Update precompile/contract_native_minter.go

* Update precompile/contract_deployer_allow_list.go

* Update precompile/allow_list.go

* add equals methods

* add new test cases for precompile configs

* use hex to address in tests

* rename helper function

* add verify to contract native minter

* add fee config tests

* add positive cases

* add equal tesets for precompile configs

* Update commontype/fee_config_test.go

* remove comment

* precompile: add formatted errors to precompile verify (#262)
2022-09-22 18:10:42 +09:00
Darioush JalaliandGitHub 0f5e956b1b GetBlockIDAtHeight: return database.ErrNotFound (#253) 2022-09-15 15:40:49 -04:00
b0e42eaa10 bump: [email protected] (#249)
* [email protected]

Signed-off-by: Sam Batschelet <[email protected]>

* *: react to bump

Signed-off-by: Sam Batschelet <[email protected]>

* bump: [email protected]

Signed-off-by: Sam Batschelet <[email protected]>

* Remove network runner dep

* remove needs from goreleaser

* Update subnet evm version to v0.3.0

Signed-off-by: Sam Batschelet <[email protected]>
Co-authored-by: Aaron Buchwald <[email protected]>
2022-09-05 03:01:44 -04:00
Darioush JalaliandGitHub 4d160e239e statesync for subnet-evm (#189)
* Unwrap ETHChain

* hook in vm.ethConfig

* statesync for subnet-evm

* remove unused configJSON

* add err check

* add synchronization

* add default config values

* delay initialization of gossiper

* Revert "add synchronization"

This reverts commit 2e8c93e58d7853de15a21ebd1460a3cd3858a6af.

* fix test

* fix statesync code prefix issue

* fix comment

* Update sync/README.md

* Update sync/README.md

* Update sync/README.md

* Update core/rawdb/accessors_state_sync.go

* port missing file from coreth

* fix-import

* subscribe before goroutine
2022-08-30 09:57:09 -04:00
05466463d6 Add comment to clarify log line won't index out of bounds (#221)
* Add comment to clarify log line won't index out of bounds

* Update plugin/evm/log.go

* Update plugin/evm/log.go

Co-authored-by: Ceyhun Onur <[email protected]>

* Fix whitespace

Co-authored-by: Ceyhun Onur <[email protected]>
2022-08-28 11:21:36 -04:00
aaronbuchwaldandGitHub 228b3f0e0d Improve json logging (#219) 2022-08-19 16:51:18 -04:00
Ceyhun OnurandGitHub 4c6aa7f4f1 Set ether base regression (#203)
* add duration marshalling

* add ether base regression test

* set etherbase from vm ethConfig

* rename package var

* re-rename avalanchego constants package var

* Update plugin/evm/vm_test.go
2022-08-17 14:45:43 -04:00
Ceyhun OnurandGitHub 55d8c5587c refactor logger & add json log format (#198)
* refactor logger & add json log format

* add fallback comment
2022-08-16 13:25:38 -04:00
Darioush JalaliandGitHub 37d4f63000 Unwrap ETHChain (#188)
* Unwrap ETHChain

* hook in vm.ethConfig
2022-08-14 23:05:51 -04:00
c82ac4714b enable/disable precompiles through upgradeBytes (#148)
* [wip] enable/disable precompile upgrades

* e2e json

* e2e genesis

* off by one

* omitEmpty -> omitempty

* custom json handling to avoid nested map

* simplify the config

* tx_pool: fix bug in calling IsTxAllowList

* precompile: add disable helpers

* plugin/evm: tentative UT

* precompile: move test helpers to their own file

* vm_test: fix gas / test

* fix copy/paste issue

* test fixes

* backward compatibility

* cleanup

* comment

* refactor: group NetworkUpgrades in struct

* rearrange Add/Disable helper methods

* move ethereum upgrades to chainConfig

* tx_gossiping_test: include eth upgrades

* vm_test: check for ErrSenderAddressNotAllowListed

* consensus/dummy: add clock

* TestTxAllowListDisablePrecompile: use clock

* vm_test.go: issueAndAccept helper / fixes

* vm_test: remove sleep

* support multiple activations/deactivations

* fix comment

* nit: simplify loop

* fix

* golang interfaces nil

* add some unit tests

* tests and fixes

* shutdown vm in test

* fix flakiness (AddRemoteSync)

* separate upgradeBytesConfig to its own struct

* add back wspace

* remove test helpers

* fix persitedUpgradeBytes

* make changes to embedding structure

* switch from getter to using an enum

* nit: fix strings

* upgrades_config.go -> precompile_config.go

* core: handle upgrade bytes in core.Blockchain

* nit: remove argument

* nit: less diff

* add equal check for StatefulPrecompileConfig

* split test

* upgrade_bytes_config_test -> upgrade_config_test

* revert AddRemoteSync -> addRemoteSync

* e2e tests: bump avalanche versions

* nit: remove args from run.sh in comments

* Upgrade nits (#167)

* Nits

* Nits

* Remove comment

* Fix

* Fixes

* upgradeBytes: verify increasing timestamps accross keys (#168)

* verify increasing timestamps accross keys

* nicer comparison

* Update plugin/evm/vm_upgrade_bytes_test.go

Co-authored-by: aaronbuchwald <[email protected]>

* unmarshal bytes to temp var

* test: reuse ctx

* test: add disable same time as enable test case

* merge (Read,Write) UpgradeConfig  w/ ChainConfig

* test disable/enable independent of timestamp

* rawdb: fix metadata accounting of upgradeConfig

* verify etherbase before genesis / minimize diff

* nit: BigNumEqual nil checks shortened version

* convert nested configs to json in String() (#175)

* Update plugin/evm/vm.go

Co-authored-by: Ceyhun Onur <[email protected]>
Co-authored-by: aaronbuchwald <[email protected]>
2022-07-30 14:28:48 -04:00
a4fd1b5a8e [AV-1898] Update [email protected] (#147)
* update versions

* Fix updated version

* use bumped ANR branch

* dep from ANR main now

* nits

Co-authored-by: Aaron Buchwald <[email protected]>
Co-authored-by: Felipe Madero <[email protected]>
Co-authored-by: Darioush Jalali <[email protected]>
2022-07-13 18:09:16 -04:00
91664ba114 init fee config precompile (#121)
* init fee config precompile

* add fee config manager precompile

* complete precompile internal functions

* nits

* add fee config provider

* init cache with limit

* added getFeeConfig func to precompile

* add fee config tasks to hardhat

* add getFeeConfigs for apis

* add unit tests

* update tx pool only if fee config is activated

* Update plugin/evm/block_verification.go

Co-authored-by: Darioush Jalali <[email protected]>

* fix for reviews

* add initial fee config to precompile & default back to chain config

* rename functions in tests

* add deployer allow list test suit

* add last accepted at

* add last accepted test to precompile test

* Revert selectBigWithinBounds changes

* use big int cmp

* move precompile test to last

* fix unit tests

* remove flaky test & ensure tx pool is reorged

* move local rpc into new file

* add comment to cachableFeeConfig

* add timestamp to block context

* add error to newOracle

* fix moar nits

* Nits

* revert allowlist setter helpers

* increase SetFeeConfigGasCost for setting last changed

* add configure validation to fee precompiles

* Address nits

* increase gas cost for wagmi

* Remove fee config from fee config manager config

* Update contract-examples/README.md

Co-authored-by: aaronbuchwald <[email protected]>

* add license to tests

* remove log

* add err check

* Update precompile/utils.go

Co-authored-by: aaronbuchwald <[email protected]>

* Remove no longer necessary test

* contract  example nits

* fix contract tests

* lower fees & split into two tests

* use explicit fees

* Nits

* feeconfig nits

* nit

* Fee config precompile nits (#145)

* Add COPYING file from geth (#83)

* Add COPYING file from geth

* Add COPYING.LESSER file

* Add version to code (#136)

* Add version to code

* bump version

* Add version to goreleaser

* Remove version from code in favor of setting at compile time

* use version env

* use v prefix in the version

Co-authored-by: Aaron Buchwald <[email protected]>

* [AV-1855] Simplify build script to place binary in avalanchego plugin directory (#81)

* Simplify build script to place binary in avalanchego plugin directory

* echo binary path

* split shutdown into network stop and client stop, call network stop
after each test, call client stop after suite ends

* add check for network up after stop

* switch to ANR

* bump script to ANR 1.1.3

* fix cluster status check

* minor fix

* cleanup of health/status check

* lint

* nits

Co-authored-by: Ceyhun Onur <[email protected]>
Co-authored-by: Darioush Jalali <[email protected]>
Co-authored-by: Aaron Buchwald <[email protected]>
2022-07-12 10:37:18 -04:00
307b38cdb3 [AV-1753] merge coreth 0.8.12 (#132)
* merge coreth 0.8.12

* add nits (#133)

Co-authored-by: Patrick O'Grady <[email protected]>
2022-06-13 19:54:50 -07:00
Patrick O'GradyandGitHub 5ea4ffe046 Bump AvalancheGo Version (#131)
* update versions

* update README

* fix breaking changes

* fix

* bump test version

* update README

* bump again
2022-06-09 18:04:48 -05:00
Ceyhun Onur 1c376b8137 nits & refactors 2022-05-25 22:54:56 +03:00
Ceyhun Onur 81982cadd9 Merge branch 'master' into metrics-pkg 2022-05-25 12:23:22 +03:00
Aaron Buchwald 256eaaf19a Always use subnetEVM genesis for vm tests 2022-05-24 21:57:14 -04:00
aaronbuchwaldandGitHub fc5f78c91b Migrate coreth nits (#109)
* nits

* Add block format section to readme
2022-05-24 15:44:28 -04:00
Ceyhun Onur 5bdfb4e11f add metrics pkg 2022-05-24 21:10:46 +03:00
Ceyhun Onur 87bc77ea47 remove helper from vm test 2022-05-24 21:10:23 +03:00
Ceyhun Onur 0c10f4f9db use value FeeConfig field in ChainConfig 2022-05-23 21:17:49 +03:00
Ceyhun OnurandGitHub c21c2d24b7 Merge branch 'master' into coreth-0.8.10-nofastsync 2022-05-23 15:18:42 +03:00
Ceyhun Onur 349599629f merge coreth 0.8.10-rc5 without fastsync & metrics package 2022-05-23 15:11:01 +03:00
Patrick O'Grady 0e7cf30611 add priority regossip to locals 2022-05-13 09:42:22 -07:00
Connor Daly 2a9d79c16c Added unit and solidity tests 2022-04-18 13:38:57 -04:00
Patrick O'Grady bed587da1a use default serve 2022-04-13 15:28:00 -07:00
Ceyhun Onur 8559c4b564 Merge branch 'master' into coreth-0.8.9-rc.0 2022-04-13 12:15:21 +03:00
Ceyhun Onur e9614d9b3c nits 2022-04-13 11:59:32 +03:00
58dc2bad41 add custom log format for chain prefix and source location (#77)
Co-authored-by: aaronbuchwald <[email protected]>
2022-04-11 19:56:30 -04:00
8bfd8d2633 Priority Regossip (#75)
* first pass

* regossip cleanup

* gossip aggressively

* add logging

* increase regossip size

* printing gap

* increase to 32

* print missing nonce

* increase slots

* more speed

* cleanup core

* update config

* moving in right direction

* increase shared logic

* update README

* add basic test

* updating config

* rewrite gossiper tx handling

* nits

* pop all txs

* make test more interesting

* fix tests

* wording cleanup

* nits

* Add PendingFrom for priority re-gossip

* Nits

* fix test

* regossip priority in normal

Co-authored-by: Aaron Buchwald <[email protected]>
2022-04-07 12:59:59 -04:00
Ceyhun Onur 99e74a2d78 merge coreth 0.8.9-rc.0 2022-04-01 03:47:21 +03:00
aaronbuchwaldandGitHub e88e729636 Bump avalanchego v1.7.9 (#67)
* Bump avalanchego to v1.7.9 and start v0.2.1 release cycle

* Fix ulimit call

* Update go.mod for simulator

* Bump to v1.7.10-rc.0
2022-03-31 17:39:10 +02:00
Patrick O'Grady 602c915270 remove unnecessary print 2022-03-16 14:04:50 -07:00
Patrick O'Grady 454f888da5 passing plugin 2022-03-16 14:03:29 -07:00
aaronbuchwaldandGitHub ce8a3e98ad Update VM ID (#58) 2022-03-14 14:28:04 -04:00
Patrick O'Grady b6e1ac4563 revert metrics changes 2022-03-06 16:39:34 -08:00
Ceyhun OnurandPatrick O'Grady 1798664491 merge coreth 0.8.6 2022-03-06 16:32:54 -08:00
Aaron Buchwald f1a335748c Mark flaky unit tests and update ci tests/coverage 2022-03-04 15:10:03 -05:00
Aaron Buchwald 1525390045 Abstract allow list and separate contract allow list 2022-03-03 08:56:55 -05:00
Patrick O'GradyandGitHub be59e41470 Merge branch 'master' into function-selectors-precompile 2022-03-02 09:36:01 -08:00
Aaron Buchwald 99b02c7799 Remove genesis contract from test genesis json configs 2022-03-01 14:46:56 -05:00
Aaron Buchwald 69d05a7c22 Add test to ensure worker generates new block correctly 2022-03-01 14:43:25 -05:00
Patrick O'Grady 78c9b64086 cleanup 31 2022-02-28 21:14:00 -08:00
Aaron Buchwald 481e467c20 WIP 2022-02-28 10:08:13 -05:00
Patrick O'Grady b72bbe2a3b fix tests 2022-02-25 18:49:15 -06:00
Aaron Buchwald 1b0812c10d Nits 2022-02-25 13:08:23 -05:00
Patrick O'Grady 951c3aa917 fix test 2022-02-15 18:19:54 -08:00
Ceyhun OnurandPatrick O'Grady a14b7cbc9b remove unused err var 2022-02-15 17:58:05 -08:00
Ceyhun OnurandPatrick O'Grady 53db54622c fix nits 2022-02-15 17:58:05 -08:00