4342 Commits

Author SHA1 Message Date
bhartnett
5e38c95a55
Merge branch 'master' into fluffy-peer-ban-list 2025-01-20 21:00:36 +08:00
bhartnett
285b6de4bc
Fluffy: Cleanup unused code from PortalProtocol (#3006) 2025-01-20 20:57:18 +08:00
bhartnett
5f91b1b685
Remove helper templates. 2025-01-20 20:40:24 +08:00
bhartnett
4b8cf1c57a
Merge branch 'master' into fluffy-peer-ban-list 2025-01-20 20:19:29 +08:00
Jordan Hrycaj
3aae33d6cc
Beacon sync maintenance update (#3012)
* Force metrics update when peers vanish

why:
  After that there might be reduced activity so that the next metrics
  update is delayed.

* Update comments (code cosmetics)

* Tidy up nano-sleep wait directives to an `update.nim`-function

* Fix copyright year
2025-01-20 10:30:04 +00:00
bhartnett
5b74335977
Update nim-rocksdb to v9.8.4.0 (#2997) 2025-01-17 18:23:24 +01:00
Advaita Saha
bf57c8e0e4
fix copyright lint failure (#3008) 2025-01-17 16:29:26 +05:30
kdeme
fa147f90ed
Portal JSON-RPC: minor clean-up (#3000)
Minor cleanup/refactor + add a basic TraceObject when returning
locally found content.
2025-01-17 11:57:15 +01:00
andri lim
aa85d6a61c
Only hashing immutable part of network configuration for dataDir ID (#2955)
* Only hashing immutable part of network configuration for dataDir ID

* Add debug- prefix to rewrite-datadir-id
2025-01-17 15:33:15 +05:30
bhartnett
db11fb16c9
Filter out and ignore banned peers in portal protocol. 2025-01-17 13:45:01 +08:00
bhartnett
000e2bbca0
Ban nodes when state network content lookups and offers fail validation. 2025-01-17 11:23:32 +08:00
bhartnett
1f7869be8c
Implement ban list data structure, banPeer and isBanned. 2025-01-16 15:19:29 +08:00
andri lim
ac053bf4c8
devnet-5: Add EIP-7840: Add blob schedule to EL config files (#3005)
* devnet-5: Add EIP-7840: Add blob schedule to EL config files

* Fix test_transaction_json

* Add missing blobSchedule to common/helpers
2025-01-16 05:10:52 +00:00
bhartnett
19ea82bf50
Fluffy: State bridge clean shutdown (#2996)
* Implement clean shutdown for state bridge.

* Handle shutdown in history and beacon bridges.
2025-01-16 08:48:10 +08:00
andri lim
232a9ad247
devnet-5: Update EIP-7702: Remove delegation behavior of EXTCODE* (#2871) 2025-01-15 14:30:26 +00:00
andri lim
5c02b88f82
devnet-5: Update EIP-2935: bring up to date with sys contract impl (#3003)
* devnet-5: Update EIP-2935: bring up to date with sys contract impl

* Fix copyright year
2025-01-15 02:42:20 +00:00
andri lim
265d794583
devnet-5: Move EIP-7702 Authorization validation to authority func (#2999)
* Move EIP-7702 Authorization validation to authority func

If the authorization is invalid the transaction itself is still valid,
the invalid authorization will be skipped.

* Fix copyright year
2025-01-15 02:18:25 +00:00
andri lim
288ee28077
Integrate PoS payload attributes into txPool (#2998)
* Integrate PoS payload attributes into txPool

* Fix test_txpool
2025-01-14 13:30:56 +00:00
bhartnett
6e83a48969
Fluffy: Refactor and organize state bridge code (#2992) 2025-01-13 16:49:35 +08:00
tersec
67a45b0a7f
rm references to unused nimbus-eth1-blobs, unused imports (#2993) 2025-01-13 09:45:12 +07:00
Siddarth Kumar
419e0193e9
blocks-import-script: swap --csv with --markdown (#2985)
This PR adds `--markdown-output` support to blocks import script.
This PR also removes `--csv-output` flag.
2025-01-10 14:17:30 +05:30
bhartnett
58d447564a
Fluffy: Improve testnet script parameters (#2989) 2025-01-10 08:48:49 +08:00
bhartnett
ec41a8d6fe
Fluffy: Add additional cli parameters for configuring the WebSocket server (#2988)
* Add additional rpc parameters for configuring the WebSocket server.
2025-01-10 08:37:44 +08:00
Advaita Saha
23fa3b8e1e
Logging Fixes for INFO and DEBUG level (#2984)
* logs summarized

* fix copyright year

* add topics for logs

* fix copyright year

* bring syncer logs to info & debug level

* fix debug dockerfile

* fix: copyright error

* shift txpool logs to debug and introduce logs in rpc

* after header bring block download to info level

* comments for finalization summary of logs

* change literals to meaningful names

* remove unwanted data from userfacing logs

* include target logs

* remove control

* fix capitalization

* complete txpool
2025-01-09 12:33:29 +05:30
bhartnett
a5194846af
Fluffy: Support gossiping content to multiple portal client endpoints in the state bridge (#2987) 2025-01-09 11:42:16 +08:00
bhartnett
13a58abf5c
Fluffy: Improve state bridge gossip retry mechanism and logging (#2986)
- Minor refactor and cleanup of gossip retry and logging.

- Wait time before verifying the gossip for a block is now proportional to the number of offers per block.

- Don't retry gossipping content after finding it in the network. When retrying gossip of a block, only the offers not yet found in the network will be re-sent.
2025-01-08 15:19:37 +08:00
andri lim
0ffc17d153
Merge test_txpool and test_txpool2 (#2983)
* Merge test_txpool and test_txpool2

* Fix copyright year
2025-01-05 08:05:29 +00:00
Siddarth Kumar
7672f0b7c0
blocks-import-script: add --csv-output flag (#2982)
This commit adds --csv-output support to blocks import script.

Github renders CSVs as tables and this addition would be useful in nimbus-eth1-benchmark repo to make this comparison easy to render.
2025-01-05 00:56:00 +05:30
bhartnett
e33ab7d468
Fluffy: Minor refactor, cleanup and improve variable names in JSON-RPC handlers (#2981) 2025-01-03 15:24:12 +08:00
bhartnett
7c347e1a2a
Fluffy: Update portal_*PutContent JSON-RPC endpoints to return metadata (#2980)
* Update portal_*PutContent JSON-RPC endpoints to return metadata as defined in the portal specs.
2025-01-02 16:28:12 +08:00
Jacek Sieka
fc9077b140
eth: bump (ecies cleanup) (#2979) 2024-12-31 16:32:21 +01:00
andri lim
7c0c507f6a
TxPool: simplify byPriceAndNonce algorithm (#2978)
Remove the intermediate bySender table usage. This will lower
the memory and CPU usage.

Also add more comments about how algorithm works.
2024-12-29 13:02:42 +07:00
Jacek Sieka
5182a0868e
json_rpc: bump (#2977) 2024-12-27 14:44:10 +00:00
andri lim
7d3616e3d9
Refactor TxPool: leaner and simpler (#2973)
* Refactor TxPool: leaner and simpler
* Rewrite test_txpool

Reduce number of tables used, from 5 to 2. Reduce number of files.
If need to modify the price rule or other filters, now is far more easier because only one table to work with(sender/nonce).
And the other table is just a map from txHash to TxItemRef.

Removing transactions from txPool either because of producing new block or syncing became much easier.
Removing expired transactions also simple.
Explicit Tx Pending, Staged, or Packed status is removed. The status of the transactions can be inferred implicitly.
Developer new to TxPool can easily follow the logic.

But the most important is we can revive the test_txpool without dirty trick and remove usage of getCanonicalHead furthermore to prepare for better integration with ForkedChain.
2024-12-26 17:07:25 +07:00
Jacek Sieka
762ef416e8
nimcrypto: bump (#2975)
* better burn/== perf
2024-12-25 20:30:31 +00:00
tersec
aeec74e310
switch to Nim v2.0.14 (#2972) 2024-12-24 15:22:29 +00:00
bhartnett
c714fa8735
Fluffy: Rename portal_*Gossip JSON-RPC endpoints to be in line with updated portal spec (#2970)
* Revert previous change in PortalStream. Allow zero as a valid connectionId if randomly generated.

* Rename portal_*Gossip JSON-RPC endpoints to portal_*PutContent to be in line with updated portal spec.
2024-12-23 15:09:48 +08:00
andri lim
487743fc2e
Proper setup of test_rpc (#2969)
Instead of using ancient/dirty code to setup the rpc test, now using newest method from TxPool and ForkedChain.
Also fix some bugs in server_api discovered when using this new setup.
2024-12-22 16:18:46 +07:00
andri lim
557a9605cf
Tidy up test_txpool2 (#2968) 2024-12-22 11:05:53 +07:00
andri lim
aba9b582db
Rename stateDB to ledger (#2966)
* Rename stateDB to ledger

* Fix readOnlyLedger
2024-12-21 20:46:13 +07:00
Kim De Mey
7112a19d6c
Adjust some portal wire and history network (error) logging (#2965) 2024-12-21 20:22:16 +07:00
andri lim
473da69043
Remove unused stuff from txpool (#2967) 2024-12-21 20:13:33 +07:00
andri lim
86fc24a1d7
devnet-5: Update EIP-7685: exclude empty requests data in commitment (#2963)
* devnet-5: Update EIP-7685: exclude empty requests data in commitment

* Fix test vector

* Add more tests

* Fix executionRequests order validation

* Simplify test vector

* Fix t8n executionRequests output
2024-12-21 05:59:30 +00:00
Jacek Sieka
036dd23e9b
cleanups, import fixes (#2964)
* more generic-path removal
* tighter imports
2024-12-20 12:57:15 +01:00
andri lim
80f8b3c2b1
devnet-5: Implement EIP-7691: Blob throughput increase (#2957) 2024-12-20 09:12:16 +00:00
andri lim
1dff892995
devnet-5: Update EIP-2537: Remove redundant MUL precompiles (#2962) 2024-12-20 05:29:30 +00:00
andri lim
6085457f9b
devnet-5: Update EIP-2537: Gas repricing (#2959) 2024-12-19 17:38:29 +00:00
Jordan Hrycaj
c801a11190
Beacon sync mainentenance updates (#2958)
* Fix name after API change

why:
  Slipped through (debugging mode)

* Fine tuning error counters

why:
  Previous operating mode was quite blunt and considered some unnecessary
  condition. Error handling was invoked and the peer zombified where one
  could have continued working with that peer.

* Provide `kvt` table API bypassing `FC`

details:
  Not a full bypass yet

why:
  As discussed on Discord:
    Ideally, those would pass through fc as well, as thin wrappers around
    the db calls, for now - later, we probably see some policy involved
    here and at that point, fc will be responsible for arbitrage between
    sources (ie if a rpc source sends the block the syncer is syncing
    while the syncer is working, fc is there to referee


* Apply `kvt` API from `FC` to beacon sync

* No need to use extra table for persistent header cache state record

why:
  Slot zero can do. This allows deleting that table wholesale when needed
  once thatfeature is available.

* Logger updates

details:
  + Lifting main header/block op logs from `trace` to `debug`
  + Set metrics update before nano-sleep (for task switch)
2024-12-19 12:02:36 +00:00
andri lim
55fd25758a
devnet-5: fix Consolidation and Withdrawal request predeploy address (#2956)
* devnet-5: fix Consolidation and Withdrawal request predeploy address

[Update EIP-7251: Set MAX_CONSOLIDATIONS=2](https://github.com/ethereum/EIPs/pull/9127)
will override
[Update EIP-7251: fix CONSOLIDATION_REQUEST_PREDEPLOY_ADDRES](https://github.com/ethereum/EIPs/pull/9118)
therefore we only need the later.

* Fix test vectors
2024-12-19 10:39:18 +00:00
Advaita Saha
48aa410f8a
reduce blockHash call (#2954) 2024-12-19 01:13:12 +05:30