-
Notifications
You must be signed in to change notification settings - Fork 748
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replace local testnet script with Kurtosis #5865
Conversation
9df8055
to
1dca23d
Compare
094c5d8
to
aa8dba7
Compare
legend |
b) BUILD_IMAGE=${OPTARG};; | ||
n) NETWORK_PARAMS_FILE=${OPTARG};; | ||
p) BUILDER_PROPOSALS=true;; | ||
c) CI=true;; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't include DEBUG_LEVEL
and VC_COUNT
, as they are already in network_parameters.yaml
and is easy to modify if needed rather than adding a bunch of flags.
Some reasoning for the default values:
BUILD_IMAGE=true
: when testing locally, we usually want to test the code in working directory, so this is on by default. If anyone wants to use latest image, can also set this to false and update the image innetwork_parameters.yaml
fileCI=false
: when testing locally, a block explorer and metrics explorer is usually handy but not useful on CI.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wondering if its easier from the end user perspective if BUILD_IMAGE
is the actual docker image that the user wants to use, and if nothing is specified, then we build the local image and use it?
e.g.
# Uses the remote docker image
./start_local_testnet -b ethpandaops/lighthouse:unstable
# Builds local image and uses that
./start_local_testnet
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the boolean flag may still be useful in the case of local testing, because if a user already have a local image and want to re-use it, then they could run it without rebuilding, and sometimes they would want to rebuild.
My thoughts around designing the params is to prefer the use the network_parameters.yaml
file where possible - this essentially replaces the vars.env
- and avoid having config in two places for simplicity and not having to worry about priority.
Same reason why I removed DEBUG_LEVEL
and VC_COUNT
from the scripts. I'm not a big fan of maintaining large shell scripts and would love to keep functionalities as small as possible.
649d699
to
48c8d40
Compare
The issue with the doppelganger tests was that the doppelganger VC was starting before epoch 1 and we currently don't support that prior to epoch 1 . See lighthouse/validator_client/src/doppelganger_service.rs Lines 407 to 416 in 3058b96
Fixed that to start the VC exactly on epoch 1 and its working fine. Although we still need to capture the exit code correctly i think. |
cc60edd
to
f2f5113
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me overall. Just a few minor nits.
I'm happy with merging this as is and addressing them in the subsequent docs PR.
b) BUILD_IMAGE=${OPTARG};; | ||
n) NETWORK_PARAMS_FILE=${OPTARG};; | ||
p) BUILDER_PROPOSALS=true;; | ||
c) CI=true;; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wondering if its easier from the end user perspective if BUILD_IMAGE
is the actual docker image that the user wants to use, and if nothing is specified, then we build the local image and use it?
e.g.
# Uses the remote docker image
./start_local_testnet -b ethpandaops/lighthouse:unstable
# Builds local image and uses that
./start_local_testnet
@mergify queue |
✅ The pull request has been merged automaticallyThe pull request has been merged automatically at 5fc0145 |
Thanks for the review @pawanjay176 , happy to discuss / address the comments above further. |
Issue Addressed
The local testnet script has become quite difficult to maintain over time and using Kurtosis for local testing is now the prefer approach.
This PR replaces the scripts with a kurtosis config file and runs the same test on CI.
TODO
new-testnet
,insecure-validators
etc)Future considerations