1204 Commits

Author SHA1 Message Date
Etan Kissling
7ad610f6d7
set fee recipient in empty payload fallback (#4291)
When the EL/Builder fails to produce an execution payload, we fall back
to an empty `ExecutionPayload`. Even though it contains no transactions
it should refer to the configured fee recipient. This is useful for
privacy reasons (do not reveal the reason for the empty payload) and for
compliance with additional fee recipient rules by staking pools.
2022-11-08 14:19:56 +00:00
tersec
909c095e64
initial automated v1.2.0 -> v1.3.0-alpha.0 consensus spec URL update (#4296) 2022-11-08 02:37:28 +00:00
Jacek Sieka
fae3ed5067
log block number / fee recipient (#4294) 2022-11-07 22:16:47 +00:00
tersec
0a43c89cd2
run capella block sanity tests in CI (#4292) 2022-11-07 18:37:48 +00:00
tersec
5b46f0b723
add Capella support to Forked* (#4276)
* add Capella support to Forked*

* remove cruft

* add `OnForkyBlockAdded`
2022-11-02 16:23:30 +00:00
tersec
3ef09ff596
Support /eth/v1/validator/blinded_blocks (#4272)
* Support BN endpoints for producing blinded blocks

* use correct endpoint version

* serve either JSON or SSZ versions of endpoint
2022-10-31 18:39:03 +01:00
Eugene Kabanov
00f083785d
VC: Fix for #4116 (external block builders support) (#4260) 2022-10-29 11:00:51 +02:00
tersec
0cfc1b776e
add all missing epoch transition tests (#4269) 2022-10-28 08:02:33 +00:00
tersec
7dd5c49c4e
use v1.3.0-alpha.0 test vectors (#4263) 2022-10-27 11:54:39 +00:00
tersec
06ccf5b80c
capella test vector support (#4261) 2022-10-27 06:29:24 +00:00
Jacek Sieka
af52edaef7
Reduce fee recipient log spam (#4255)
Once is enough
2022-10-25 14:47:43 +02:00
tersec
f9830836a9
deprecate --terminal-total-difficulty-override; remove launch script for deprecated ropsten (#4241)
* deprecate --terminal-total-difficulty-override; remove launch script for deprecated ropsten

* remove Makefile support for Ropsten
2022-10-24 23:32:52 +03:00
tersec
fb6e6d9cf4
remove newPayload from block production flow (#4186)
* remove `newPayload` from block production flow

* refactor block_processor to run `newPayload` as part of `storeBlock`
2022-10-14 22:48:56 +03:00
Zahary Karadjov
89582c10db
Merge branch 'stable' into unstable 2022-10-14 22:24:55 +03:00
cheatfate
b54a03ae07
Fix MEV builder file descriptor leaks. 2022-10-14 16:09:39 +03:00
Etan Kissling
95aec9de12
update to v1 of LC REST API (#4232)
The LC REST API has been merged into the ethereum/beacon-APIs specs:
- https://github.com/ethereum/beacon-APIs/pull/247

Update URLs to v1 and update REST tests. Note that REST tests do not
start with Altair, so the tested BN will return empty / error responses.
2022-10-13 13:42:53 +03:00
Etan Kissling
4b7bb4796f
update for latest LC REST proposal (#4213)
Implements the latest proposal for providing LC data via REST, as of
https://github.com/ethereum/beacon-APIs/pull/247 with a v0 suffix.

Requests:
- `/eth/v0/beacon/light_client/bootstrap/{block_root}`
- `/eth/v0/beacon/light_client/updates?start_period={start_period}&count={count}`
- `/eth/v0/beacon/light_client/finality_update`
- `/eth/v0/beacon/light_client/optimistic_update`

HTTP Server-Sent Events (SSE):
- `light_client_finality_update_v0`
- `light_client_optimistic_update_v0`
2022-10-13 13:42:46 +03:00
Etan Kissling
3a4b87358a
update to v1 of LC REST API (#4232)
The LC REST API has been merged into the ethereum/beacon-APIs specs:
- https://github.com/ethereum/beacon-APIs/pull/247

Update URLs to v1 and update REST tests. Note that REST tests do not
start with Altair, so the tested BN will return empty / error responses.
2022-10-13 02:16:49 +02:00
tersec
16817fef95
cleanups: proc -> func, unused import, spec URLs (#4224) 2022-10-08 05:07:54 -05:00
tersec
ce915c0a03
add beaconcha.in mainnet relay overview to guide (#4217) 2022-10-04 19:45:06 +03:00
Etan Kissling
7202acddff
update for latest LC REST proposal (#4213)
Implements the latest proposal for providing LC data via REST, as of
https://github.com/ethereum/beacon-APIs/pull/247 with a v0 suffix.

Requests:
- `/eth/v0/beacon/light_client/bootstrap/{block_root}`
- `/eth/v0/beacon/light_client/updates?start_period={start_period}&count={count}`
- `/eth/v0/beacon/light_client/finality_update`
- `/eth/v0/beacon/light_client/optimistic_update`

HTTP Server-Sent Events (SSE):
- `light_client_finality_update_v0`
- `light_client_optimistic_update_v0`
2022-10-04 13:38:09 +02:00
Etan Kissling
83cd104d07
add section headers for REST serialization (#4210)
Adds missing REST serialization sections and makes them consistent.
2022-10-03 22:29:07 +00:00
Etan Kissling
231eb8a590
use same style for sending block and state rsps (#4209)
For JSON responses, "eth-consensus-version" header is handled in
`eth2_rest_serialization` for states and `rest_beacon_api` for blocks.
Align them to also be handled in `eth2_rest_serialization` for blocks.
2022-10-04 01:05:52 +03:00
tersec
ad7541567c
move LVH handling to tests/; increase maximum fork choice retries (#4205) 2022-10-03 13:10:08 +00:00
tersec
0a4aa5fdb3
switch withStateAndBlck usage to forkyState; rm unused tests/mocking/ modules (#4206) 2022-10-03 13:08:50 +00:00
Eugene Kabanov
a845450283
REST API: add ssz encoding for publishBlock (#4154) 2022-09-30 00:00:53 +03:00
Jacek Sieka
af9ec577d0
nicer error message for failed backfill (#4188)
* nicer error message for failed backfill

Many checkpoint sources don't support block download

* RestGenericError -> RestErrorMessage

...and other assorted fixes to bring rest types closer to spec

* fix tests
2022-09-29 23:55:18 +03:00
tersec
c367b14ad9
deprecate --safe-slots-to-import-optimistically (#4182) 2022-09-29 06:29:49 +00:00
Eugene Kabanov
8778e1cf8d
Fix REST generic error parsing. (#4189)
* Fix REST generic error parser.
* Unescape test vectors.
* Fix RestGenericError writer and tests, to encode `code` as `Number`.
2022-09-28 18:47:15 +00:00
Jacek Sieka
c11b30f8e1
Remove deprecated REST API calls from client (#4190)
* https://github.com/ethereum/beacon-APIs/pull/220
* https://github.com/ethereum/beacon-APIs/pull/218
2022-09-28 10:37:54 +00:00
tersec
57d68d0f72
re-enable randao checks (#4187)
* re-enable randao checks

* use `asSigVerified` consistently

* fix spelling

* document why state_transition.makeBeaconBlock trusting signatures is safe
2022-09-28 01:15:10 +00:00
tersec
a0ead042ad
newPayload INVALIDATED should be unviableFork (#4180) 2022-09-26 21:24:32 +00:00
tersec
9750cd3a38
update state diffs to Bellatrix (#4177) 2022-09-26 19:13:50 +00:00
Etan Kissling
d76df065a1
rm unused dump function for KeystoresAndSlashingProtection (#4170)
In `eth2_rest_serialization` there was a `dump` function for
`KeystoresAndSlashingProtection` that does not seem to be used.
Removes that unused function.
2022-09-26 21:09:51 +02:00
Etan Kissling
7ac95c6ee7
move EpochParticipationFlags serialization to others (#4167)
The REST `writeValue/readValue` serialization functions are grouped up
with the exception of `EpochParticipationFlags`. Moving that to others.
2022-09-23 18:29:31 +00:00
Etan Kissling
77ea188c92
add sszResponsePlain for pre-encoded SSZ data (#4171)
For pre-encoded JSON REST responses we have `jsonResponsePlain`.
Adds a `sszResponsePlain` function to serve similar purpose for SSZ.
This avoids caller having to explicitly specify Http200 and media type.
2022-09-23 15:51:04 +00:00
Etan Kissling
8b11778e14
use withState in jsonResponseState (#4169)
The generic sandwich preventing `forks.withState` from working in REST
serialization is no longer applicable. Update to use `withState`.
2022-09-23 13:49:22 +00:00
Etan Kissling
cd626cf645
delete unused REST version constants (#4166)
Removes unused `Phase0Version` and `AltairVersion` constants.
2022-09-23 12:48:53 +00:00
tersec
deb043796b
a few more manual v1.2.0 consensus spec ref URL updates (#4165) 2022-09-23 12:00:17 +00:00
tersec
3c03ba86c1
update consensus spec ref URLs to v1.2.0 (#4164) 2022-09-23 07:56:06 +00:00
tersec
72e6b2021a
use v1.2.0 consensus spec test vectors (#4163) 2022-09-22 22:24:13 +00:00
Michael Sproul
d6325b1ab5
api: add skip_randao_verification for produceBlockV2 (#3837) 2022-09-21 09:38:08 +02:00
tersec
56720dd808
update consensus layer spec ref URLs to v1.2.0-rc.3 (#4143) 2022-09-20 02:08:09 +02:00
zah
ad63bba446
Support Prysm and Ethdo Keystores (Fixes #4107) (#4149) 2022-09-20 01:09:56 +03:00
tersec
e3750e96e8
fix order of current/previous dependent root in REST SSE (#4141) 2022-09-19 13:28:52 +03:00
Eugene Kabanov
ca871a5435
Fix HTTP/REST clients HTTP Content-Type header parsers. (#4139)
* Fix client HTTP content-type parsers.

* Fix tests.

* Address review comment and apply wildcard checks for generic decodeBytes.
2022-09-19 12:17:29 +03:00
Etan Kissling
9999362b11
detect mismatch of config and binary (#4132)
* detect mismatch of config and binary

When loading configuration that sets keys that Nimbus bakes into the
binary at compile-time, raise an error if the config is incompatible
instead of ignoring the conflicting value.
2022-09-19 12:07:46 +03:00
Jacek Sieka
ef8bab58eb
load suggested fee recipient file also when keymanager is disabled (#4078)
Since these files may have been created in a previous run or manually,
we want to keep loading them even on nodes that don't enable the
keystore API (for example static setups)

Other changes:

* log keystore loading progressively (#3699)
* print initial fee recipient when loading validators
* log dynamic fee recipient updates
2022-09-17 08:30:07 +03:00
tersec
0410aec9d8
remove rest of withState.state usage (#4120)
* remove rest of `withState.state` usage

* remove scaffolding
2022-09-16 15:35:00 +02:00
Jacek Sieka
43188a0990
clean up exchange configuration handling (#4126)
Per spec, we should not be sending our detected terminal block to EL -
the EL configuration exchange should only look at values from
configuration and report mismatches.
2022-09-16 15:33:22 +02:00