Commit Graph

86 Commits

Author SHA1 Message Date
chonghe
976bcf3f1a Merge branch 'sigp:stable' into book-cli 2023-10-03 19:08:52 +08:00
chonghe
2c798e2777 move then to same line as if 2023-10-03 19:04:21 +08:00
chonghe
ff229b455f remove maxperf 2023-10-03 19:00:28 +08:00
chonghe
f34792abb3 Update scripts/cli.sh
Co-authored-by: Mac L <mjladson@pm.me>
2023-10-03 18:52:39 +08:00
chonghe
535933ea16 Update scripts/cli.sh
Co-authored-by: Mac L <mjladson@pm.me>
2023-10-03 18:52:02 +08:00
Jimmy Chen
fe3bd03234 Fix local testnet to generate keys in the correct folders (#4752)
Fix local testnet to generate keys in the correct folders when `BN_COUNT` and `VC_COUNT` don't match.

The current script place the generated validator keys in validator folders based on the `BN_COUNT` config, e.g. `node_1/validators`, `node_2/validators`..etc. We should be using `VC_COUNT` here instead, otherwise the number of validator clients may not match the number of directories generated, and would result in either:
1. a VC not having any keys  (when `BN_COUNT` < `VC_COUNT`)
2. a validator key directory not being used (when `BN_COUNT` > `VC_COUNT`).
2023-09-21 00:26:56 +00:00
chonghe
f9a3c00518 Update local testnet script (#4733)
There is an issue with the file `scripts/local_testnet/start_local_testnet.sh` - when we use a non-default `$SPEC-PRESET` in `vars.env` it runs into an error: 
```
executing: ./setup.sh >> /home/ck/.lighthouse/local-testnet/testnet/setup.log
parse error: Invalid numeric literal at line 1, column 7
```
@jimmygchen found the issue and the updated script includes the flag `--spec $SPEC-PRESET`
2023-09-21 00:26:55 +00:00
chonghe
7cd6a18ae9 update 2023-09-15 23:20:02 +08:00
chonghe
4e4ec7e71b remove troubleshooting part 2023-09-15 23:16:57 +08:00
chonghe
27d1fb034d revise 2023-09-15 22:03:53 +08:00
chonghe
cb71c7580a add exist and update for future debug 2023-09-15 22:03:36 +08:00
chonghe
ab2574ccdf change back non-debug mode 2023-09-15 21:41:25 +08:00
chonghe
314745a094 add vm 2023-09-15 21:18:31 +08:00
chonghe
5a5bbe7b39 Merge pull request #3 from chong-he/unstable
Merge Unstable
2023-09-15 20:38:31 +08:00
chonghe
9091ebdd4c test 2023-09-15 20:02:05 +08:00
chonghe
34a149a207 Merge branch 'sigp:stable' into book-cli 2023-09-15 18:11:04 +08:00
chonghe
1aaca5b46c testing 2023-09-15 17:39:52 +08:00
chonghe
09f81a4dd2 testing 2023-09-15 17:12:21 +08:00
chonghe
f1c2b542fc test 2023-09-15 16:20:11 +08:00
chonghe
a16c586c09 test make cli 2023-09-15 15:56:56 +08:00
Age Manning
e4ed317b76 Add Experimental QUIC support (#4577)
## Issue Addressed

#4402 

## Proposed Changes

This PR adds QUIC support to Lighthouse. As this is not officially spec'd this will only work between lighthouse <-> lighthouse connections. We attempt a QUIC connection (if the node advertises it) and if it fails we fallback to TCP. 

This should be a backwards compatible modification. We want to test this functionality on live networks to observe any improvements in bandwidth/latency.

NOTE: This also removes the websockets transport as I believe no one is really using it. It should be mentioned in our release however.


Co-authored-by: João Oliveira <hello@jxs.pt>
2023-09-15 03:07:24 +00:00
chonghe
971bee38d1 remove vm.md 2023-09-15 09:39:32 +08:00
chonghe
7f2f9d1345 function 2023-09-15 09:38:10 +08:00
chonghe
ed31b6b077 comment 2023-09-06 16:39:52 +08:00
chonghe
a180809238 Revise cli.sh 2023-09-06 16:39:03 +08:00
chonghe
51b7de4717 Fixed permission 2023-09-06 11:33:07 +08:00
chonghe
fb6f3537bb Indentation and revision 2023-09-06 11:28:59 +08:00
chonghe
cb22bd3c5f remove files 2023-09-05 22:46:09 +08:00
chonghe
c3d1bf3719 Move cli.sh 2023-09-05 21:11:31 +08:00
chonghe
4f111a2e51 Update cli and makefile 2023-09-05 21:01:05 +08:00
chonghe
2d1325c6a1 change exit 1 2023-08-30 21:52:35 +08:00
chonghe
07b9a8fd86 test old cli_manual 2023-08-27 22:09:12 +08:00
chonghe
1e31d33f7d Correct cli.txt directory 2023-08-27 20:25:11 +08:00
chonghe
17786611a0 Update directory in Github 2023-08-27 19:07:35 +08:00
chonghe
e332bee66f Revise to update 2023-08-27 17:26:11 +08:00
chonghe
3c7002811e cli_manual 2023-08-18 08:18:02 +08:00
chonghe
1c1d50d219 update cmd 2023-08-09 21:18:46 +08:00
Mac L
d4170c5698 Fix cli.sh permissions 2023-08-07 11:59:38 +10:00
chonghe
090d20bb8c modified test-suite 2023-08-07 09:01:47 +08:00
Divma
ff9b09d964 upgrade to libp2p 0.52 (#4431)
## Issue Addressed

Upgrade libp2p to v0.52

## Proposed Changes
- **Workflows**: remove installation of `protoc`
- **Book**: remove installation of `protoc`
- **`Dockerfile`s and `cross`**: remove custom base `Dockerfile` for cross since it's no longer needed. Remove `protoc` from remaining `Dockerfiles`s
- **Upgrade `discv5` to `v0.3.1`:** we have some cool stuff in there: no longer needs `protoc` and faster ip updates on cold start
- **Upgrade `prometheus` to `0.21.0`**, now it no longer needs encoding checks
- **things that look like refactors:** bunch of api types were renamed and need to be accessed in a different (clearer) way
- **Lighthouse network**
	- connection limits is now a behaviour
	- banned peers no longer exist on the swarm level, but at the behaviour level
	- `connection_event_buffer_size` now is handled per connection with a buffer size of 4
	- `mplex` is deprecated and was removed
	- rpc handler now logs the peer to which it belongs

## Additional Info

Tried to keep as much behaviour unchanged as possible. However, there is a great deal of improvements we can do _after_ this upgrade:
- Smart connection limits: Connection limits have been checked only based on numbers, we can now use information about the incoming peer to decide if we want it
- More powerful peer management: Dial attempts from other behaviours can be rejected early
- Incoming connections can be rejected early
- Banning can be returned exclusively to the peer management: We should not get connections to banned peers anymore making use of this
- TCP Nat updates: We might be able to take advantage of confirmed external addresses to check out tcp ports/ips


Co-authored-by: Age Manning <Age@AgeManning.com>
Co-authored-by: Akihito Nakano <sora.akatsuki@gmail.com>
2023-08-02 00:59:34 +00:00
chonghe
0374cf6068 update 2023-08-01 10:12:27 +08:00
Michael Sproul
b96cfcaaa4 Fix bug in lcli transition-blocks and improve pretty-ssz (#4513)
## Proposed Changes

- Fix bad `state_root` reuse in `lcli transition-blocks` that resulted in invalid results at skipped slots.
- Modernise `lcli pretty-ssz` to include fork-generic decoders for `SignedBeaconBlock` and `BeaconState` which respect the `--network`/`--testnet-dir` flag.

## Additional Info

Breaking change: the underscore names like `signed_block_merge` are removed in favour of the fork-generic name `SignedBeaconBlock`, and fork-specific names which match the superstruct variants, e.g. `SignedBeaconBlockMerge`.
2023-07-31 01:53:05 +00:00
chonghe
542afe139c update Makefile 2023-07-17 09:20:23 +08:00
Jimmy Chen
68d5a6cf99 Clean up local testnet files without prompting (#4498)
## Issue Addressed

Addresses an issue where CI could fail due to an nonexisting file error:

```
Run ./clean.sh
rm: cannot remove '/home/runner/.lighthouse/local-testnet/geth_datadir4/geth/fastcache.tmp.1549331618': No such file or directory
Error: Process completed with exit code 1.
```

This seems to happen quite frequently now, I'm not sure exactly why but perhaps worth trying suppressing the prompt?

https://github.com/sigp/lighthouse/actions/runs/5455027574/jobs/9925916159?pr=4463
2023-07-17 00:14:17 +00:00
chonghe
5400b6e0d0 update bash script 2023-07-15 15:51:03 +08:00
chonghe
a31901f169 Add cli.sh file 2023-06-16 10:26:26 +08:00
Jimmy Chen
e6deaad91e Remove unused crate publishing Github action and script (#4347)
## Issue Addressed

`publish-crate` action and its script no longer used after https://github.com/sigp/lighthouse/pull/3890.
2023-05-30 06:15:58 +00:00
Pawan Dhananjay
a7da331f6a Fix geth scripts (#4342)
## Issue Addressed

N/A

## Proposed Changes

Geth's latest release breaks our CI with the following message
```
Fatal: Failed to register the Ethereum service: ethash is only supported as a historical component of already merged networks
Shutting down
```
Latest geth version has removed support for PoW networks. Hence, we need to add an extra `terminalTotalDifficultyPassed ` parameter in the genesis config to start from a merged network.
2023-05-30 01:38:50 +00:00
Pawan Dhananjay
91a7f51ab0 Post merge local testnets (#3807)
## Issue Addressed

N/A

## Proposed Changes

Modifies the local testnet scripts to start a network with genesis validators embedded into the genesis state. This allows us to start a local testnet without the need for deploying a deposit contract or depositing validators pre-genesis.

This also enables us to start a local test network at any fork we want without going through fork transitions. Also adds scripts to start multiple geth clients and peer them with each other and peer the geth clients with beacon nodes to start a post merge local testnet.

## Additional info

Adds a new lcli command `mnemonics-validators` that generates validator directories derived from a given mnemonic. 
Adds a new `derived-genesis-state` option to the `lcli new-testnet` command to generate a genesis state populated with validators derived from a mnemonic.
2023-05-17 05:51:54 +00:00
Pawan Dhananjay
8a3eb4df9c Replace ganache-cli with anvil (#3555)
## Issue Addressed

N/A

## Proposed Changes

Replace ganache-cli with anvil https://github.com/foundry-rs/foundry/blob/master/anvil/README.md
We can lose all js dependencies in CI as a consequence.

## Additional info
Also changes the ethers-rs version used in the execution layer (for the transaction reconstruction) to a newer one. This was necessary to get use the ethers utils for anvil. The fixed execution engine integration tests should catch any potential issues with the payload reconstruction after #3592 


Co-authored-by: Michael Sproul <michael@sigmaprime.io>
2023-05-15 07:22:02 +00:00