Commit Graph

169 Commits

Author SHA1 Message Date
Alex Sharov
05e77cb4d3
get block receipts method (#1735) 2021-04-18 12:05:54 +07:00
Artem Vorotnikov
86f3190806
trace_block: fix block number in traces (#1731) 2021-04-15 21:58:06 +03:00
Artem Vorotnikov
c935f7a996
trace_block: execute block on top of previous block (#1720) 2021-04-15 13:48:42 +03:00
Alex Sharov
5703059f29
[merge after release] Move history stage to rwtx (#1727) 2021-04-15 17:06:30 +07:00
Alex Sharov
4ef5e4b2f6
Continue move to rwtx (#1722) 2021-04-15 12:23:10 +07:00
Artem Vorotnikov
307a120af2
trace_block (part 2) (#1719) 2021-04-15 02:50:17 +03:00
Artem Vorotnikov
ba5090064c
Remove vmTrace from trace_block (#1718) 2021-04-15 00:48:44 +03:00
Artem Vorotnikov
58fca1cd0a
trace_block (part 1) (#1714) 2021-04-15 00:44:58 +03:00
Alex Sharov
c3776f7539
[merge after release] handle case when no senders in db yet (#1695) 2021-04-08 22:03:22 +07:00
Alex Sharov
9cff853d1e
tx less wrappers (#1694) 2021-04-08 18:03:45 +07:00
Alex Sharov
a913ae8847
Remove chainContext object (#1683) 2021-04-06 16:52:53 +07:00
Artem Vorotnikov
b71c6323a0
KVGetter, replace old geth interfaces with it (#1676) 2021-04-05 20:04:58 +07:00
Artem Vorotnikov
d66555268d
Harmonize DB APIs (#1669) 2021-04-03 09:26:00 +03:00
Alex Sharov
9a9c5b298a
bitmapdb to use rwtx (#1661) 2021-04-03 08:52:45 +07:00
Alex Sharov
66d1d5d1f8
corner_case_return_null_when_block_not (#1646) 2021-04-01 12:15:22 +07:00
Alex Sharov
527fafe051
estimate_gas: to accept optional block or hash (#1639) 2021-03-31 11:32:52 +07:00
Alex Sharov
930b9ae37c
infinite gas cap for gas estimate (#1638) 2021-03-31 11:03:52 +07:00
Artem Vorotnikov
d4c10c9a47
Port rpcdaemon to KV interface (#1627) 2021-03-30 12:53:54 +03:00
Alex Sharov
86ccfd0338
RPC: Pending transactions/blocks/logs (#1625) 2021-03-30 14:09:00 +07:00
Artem Vorotnikov
9b8cdc0f22
Fix lints and remove more unused code (#1621) 2021-03-29 10:58:45 +07:00
ledgerwatch
3b18c02edf
Lazy fix for eth_getLogs (#1620)
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-03-28 19:47:20 +01:00
Alex Sharov
416a69ecb3
Genesis.toBlock remove db from arguments (#1611) 2021-03-28 16:27:06 +07:00
Alex Sharov
aff859edc0
Mining stage (#1554) 2021-03-23 16:00:07 +07:00
Igor Mandrigin
a122920fa8 and more lint fixes 2021-03-18 11:53:34 +01:00
Alexey Sharp
50ea8f4e20 Fix cmd/rpcdaemon tests 2021-03-17 16:49:02 +00:00
Alexey Sharp
0a91c9fa9a More compilation fixes 2021-03-15 19:37:37 +00:00
Alexey Sharp
af495562e4 Fix rcpdaemon compilation 2021-03-14 18:52:15 +00:00
ledgerwatch
b743b88218
Revert "Extract validating interface (#1120)" (#1543)
* Revert "Extract validating interface (#1120)"

This reverts commit e4e36c152e.

* Fix go mod tidy

* Fix lint

* Fix lint

* fix lint

* Test fix

* Fix test

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-03-05 20:34:23 +00:00
Alex Sharov
eb7d2ad16a
Add validation of senders amount (#1539) 2021-03-04 16:34:49 +07:00
ledgerwatch
c00f85ab6c
Simplification of eth_estimageGas (#1531)
* Simplification of eth_estimageGas

* Set GasCap by default

* Add a test

* Fix crash

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-03-02 22:47:44 +00:00
Evgeny Danilenko
e4e36c152e
Extract validating interface (#1120)
* interface

* generalize interface

* linters

* fix deadlock

* fix linters

* close goroutine

* fix

* debug

* id+ttl

* refactor downloader tests

* tests

* lru

* handle genesis, extract fake consensuses

* fix fake consensus

* test uncles, verify

* after a new master

* fmt

* fix close

* debug

* debug

* fix chain length

* remove test field

* use single account

* fix data race on closing channel

* remove postponed blocks queue

* miner test

* VerifyHeaderRequests

* fmt

* fmt

* fix data race

* handle validating errors

* simplify matchParents

* remove copy-paste

* move sort to constructor

* clean up

* debug for 10 parents

* debug

* debug

* batch responses

* batch requests

* works for many ancestors

* remove debug

* always Close an engine

* linters

* ancestors deduplication

* fix test

* reduce interface

* api

* clique

* green clique sync

* stable

* perpermance per second

* full sync

* linters

* gitignore

* deps

* fix panic after master merge

* init consensus

* clique tests

* fix tests

* fix tests

* clean up

* reuse snap

* store vefified snapshots

* optimize snapshots

* safe close

* cleanup loop

* after downloader

* downloader and consensus tests

* update tests

* hack.go

* clique flags

* fix cliuqe config

* review

* gitignore

* remove additional bucket

* blk/sec instead of blk/microsecond

* rename

* deps

* optimize

* debug

* test

* tests without extracted validation process

* same base performance as on master

* benchmark

* simplify ethash verification

* ethash

* ethash

* linters

* ethash

* master stats

* cleanup

* gomod

* linters

* tests

* better locks

* Fix

* Remove logging for verifyHeaders

* Verification speed in the logs

* Fix compile error

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-02-25 19:40:45 +00:00
ledgerwatch
dc6b4c0e43
Fixes for trace_callMany (#1506)
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-02-21 20:18:59 +00:00
ledgerwatch
e8501bbf43
eth_getTransactionReceipt to return nil for transactions not in the d… (#1505)
* eth_getTransactionReceipt to return nil for transactions not in the database

* Fix compile error
2021-02-21 09:38:00 +01:00
ledgerwatch
7c81e9198d
Fixes to trace_call, trace_callMany, dual RPC daemon mode (#1491)
* Fixes to trace_call, trace_callMany, dual RPC daemon mode

* Fix compile error

* Fix compile error

* Compile error fix

* Compile error fix

* Fix typo

* Fix discrepancy when trace is empty

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-02-12 16:47:32 +00:00
ledgerwatch
bb2cc5a10e
debug_accountAt (#1487)
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-02-10 20:43:13 +00:00
ledgerwatch
2daa71e6cb
Support for trace_callMany (#1486)
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-02-10 17:04:47 +00:00
Artem Vorotnikov
5c34713e71
Remove nested transactions (#1483) 2021-02-10 17:04:22 +00:00
ledgerwatch
7c8bae8591
Implementation of debug_traceCall, add stateDiff to trace_call (#1442)
* Implementation of debug_traceCall

* Fix compile error

* Implementing stateDiff in trace_call - WIP

* fixes to stateDiff, better parsing in rpctest

* Fix lint

* Fix lint

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-01-18 11:13:19 +00:00
Alex Sharov
75cb938980
rpcdaemon performance improve - less reading blocks, less allocs on server (#1426)
* rpcdaemon performance improve - less reading blocks, less allocs on server

* rpcdaemon performance improve - less reading blocks, less allocs on server

* rpcdaemon performance improve - less reading blocks, less allocs on server

* rpcdaemon performance improve - less reading blocks, less allocs on server

* don't use global variables

* df

* avoid use non-transactional db instance to reduce amount of cursors
2021-01-02 19:28:22 +00:00
Artem Vorotnikov
8c0ecaeea9
Remove StageData (#1419) 2020-12-21 11:01:37 +00:00
ledgerwatch
0953fd42cb
WIP trace_call implementation (#1399)
* trace_call initial

* Fix tests

* More tracing

* Add more fields to the action

* Completed first example query

* Add initial bench11 to compare trace_call with OpenEthereum

* Exclude precompile calls from call traces

* Add self-destruct, call types, more comparison in rpctest

* Support for execution errors

* Stack underflow error and delegatecall value

* Fix lint

* Fix suicide traceAddress, Bad instruction error

* Fix lint

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2020-12-14 11:27:52 +00:00
ledgerwatch
2cc36dac87
further cleanup, unit tests for RPC daemon and tracing improvements (#1392)
* Cleanup and rpcdaemon unit tests

* Fix

* Fix

* Fix lint

* Test for debug_traceTransaction

* Add NoRefunds option

* Compile fix, test for no refunds

* Fix compile

* Add poly contract, fix compile errors

* No refunds now work

* Fix NPE in rpcdaemon

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2020-12-09 18:24:08 +00:00
ledgerwatch
5ea590c18e
State cache switching writes to reads during commit (#1368)
* State cache init

* More code

* Fix lint

* More tests

* More tests

* More tests

* Fix test

* Transformations

* remove writeQueue, before fixing the tests

* Fix tests

* Add more tests, incarnation to the code items

* Fix lint

* Fix lint

* Remove shards prototype, add incarnation to the state reader code

* Clean up and replace cache in call_traces stage

* fix flaky test

* Save changes

* Readers to use addrHash, writes - addresses

* Fix lint

* Fix lint

* More accurate tracking of size

* Optimise for smaller write batches

* Attempt to integrate state cache into Execution stage

* cacheSize to default flags

* Print correct cache sizes and batch sizes

* cacheSize in the integration

* Fix tests

* Fix lint

* Remove print

* Fix exec stage

* Fix test

* Refresh sequence on write

* No double increment

* heap.Remove

* Try to fix alignment

* Refactoring, adding hashItems

* More changes

* Fix compile errors

* Fix lint

* Wrapping cached reader

* Wrap writer into cached writer

* Turn state cache off by default

* Fix plain state writer

* Fix for code/storage mixup

* Fix tests

* Fix clique test

* Better fix for the tests

* Add test and fix some more

* Fix compile error|

* More functions

* Fixes

* Fix for the tests

* sepatate DeletedFlag and AbsentFlag

* Minor fixes

* Test refactoring

* More changes

* Fix some tests

* More test fixes

* More test fixes

* Fix lint

* Move blockchain_test to be able to use stagedsync

* More fixes

* Fixes and cleanup

* Fix tests in turbo/stages

* Fix lint

* Fix lint

* Intemediate

* Fix tests

* Intemediate

* More fixes

* Compilation fixes

* More fixes

* Fix compile errors

* More test fixes

* More fixes

* More test fixes

* Fix compile error

* Fixes

* Fix

* Fix

* More fixes

* Fixes

* More fixes and cleanup

* Further fix

* Check gas used and bloom with header

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2020-12-08 09:44:29 +00:00
Alex Sharov
98b36126b2
History bitmap 64 (#1374)
* squash

* squash

* squash

* squash

* squash

* squash

* subscription_doesnt_preserve_shutdown
2020-12-04 21:16:51 +00:00
Alex Sharov
27a24746b7
remove GetLogsByHash (#1390) 2020-12-04 10:27:24 +00:00
Thomas Jay Rush
362e9a1773
Update docs testing (#1385)
* Remove unused files

* Updating testing definition

* Updating auto-generated docs

* Update go code to make agree with silkrpc testing
2020-12-04 10:24:49 +00:00
ledgerwatch
9a233da93d
Add test for getChainConfig (#1375)
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2020-11-28 15:08:17 +00:00
Alex Sharov
068463dff4
Store transactions individually (#1358)
* Store transactions individually

* Store transactions individually

* save progress

* checkIndex

* merge
2020-11-22 21:25:26 +00:00
ledgerwatch
1a0e78a2e2
Remove changeset-based decorators from WalkAsOf (#1356)
* Remove decorators

* Current changes

* Fix and skip some tests for now

* Fix lint

* Specialise WalkAsOf

* Fix compile errors

* Fix lint

* Scan index files for key sizes

* More cleanup

* Fix to remote server

* Fix for walkasofstorage

* Fix/skip tests

* Fix tests

* Fix lint

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2020-11-18 14:58:52 +00:00
Igor Mandrigin
393c9965ae
rpcdaemon: subscriptions, newHeads (#1359)
* fix `make grpc` on new checkouts

* update proto files

* add some stub

* prototype with fake events

* notifying about events

* pass events

* events are being sent

* transfer headers to filters

* create the “filters” struct

* implement new heads

* PoC of New Heads subscription

* fix keep alive

* fixups for the client

* add “type” to the event

* support header event type on client

* better stage refactor

* fixup for the eth backend

* fixups

* fix tests

* fix tests

* fix linters

* address comments

* remove unused log
2020-11-17 19:13:41 +00:00