Mario Havel - Introduction to Ephemery testnet

EthStaker at Devconnect Istanbul 2023 · November 2023 · 15:44

Explores introduction to Ephemery testnet.

Speakers

Topics

From EthStaker at Devconnect Istanbul 2023, hosted by Eth Staker.

Transcript

ready go all right excellent we'll go ahead and uh continue on um our next speaker here is Mario uh Mario is with the ethereum foundation and protocol support welcome thank so much thanks thanks a lot oh wow I appreciate that especially I mean it feels a bit weird sing here after uh Denny and Justin and having like well pretty serious talks and on very important topics and well I also bring um you know important topic but uh especially to stakers and U uh yeah so yeah I'm Mario from ether Foundation

protol support and today I would like to tell tell you about a family testet or actually more of also in general specification of a new kind of test on ethereum uh before we get into uh the testnet itself maybe we should like give a overview of what test Nets are even even uh but I guess I don't need to explain it here you guys being stakers I guess you experienced um what test net is or might be and uh uh just in general ethereum is a network so if we want to test things uh we need to spin up a separate Network where we don't handle uh real money where we can just you know play around with various kinds of stuff and that can be in ethereum the changes to clients themselves changes to

protocol so test nets for protocol changing or for protocol upgrade or for um uh users and those can be well the developers creating uh contracts and all the all the applications on ethereum and uh you folks stakers uh who want to test your staking setups on testnet so what is the current state of the ethereum test Nets when you want to do either of these so after the merge we killed some of the old test Nets the robsten is uh as we call it the ripston now now it's it's terrible joke uh but yeah so what survived was gly and sepolia uh with um them uh being um um dedicated to different use cases AOA

mostly for users for uh de developers and gly especially for stakers because it had the open validator said I'm saying head because it's kind of history now G got deprecated in favor of new test net holit holes key named after PR 7 uh which has also opened um volor set and uh to be fair pretty large vol said it's 1.5 million validators three times size of mayet so if you want to test your validator setup hollish key right now would be the place to go and it's still kind of fresh because it's uh uh because it's uh just what two months old now after the second successful lunch attempt uh however these test Nets are uh meant to run for uh many years to

come and uh as G got deprecated for some obvious reasons if uh you've been familiar with most of the supply issues with Gurley so after the years of people you know using it testing it draining the faucets there is not enough testet eat in the faucets because there was only so much created in the Genesis so uh the one of the main problems that the test Nets which are running for years um encounter is that they just don't have enough eat to just give out for free with uh like little proof of work from the users so it can get expensive or hard to to acquire some uh uh tokens for your testing and uh uh what we saw with girlyy especially with uh being it used

for Prater uh for many years uh it not just wasted the funds but also created many validators which just appeared for once people just come and try their validator and uh then turn off the machine they switch to main at and and they're gone forever so uh what we have is bunch of inactive zombie validators which cause uh missed blocks or maybe in worst case even um not able to the network might not be able to reach the finality and of course as the um the network is growing uh it it gets older it's growing the state uh gets quite big so we can have like hundreds of gigabytes of uh just test net data if you want to run the note or try your validator and uh yeah and all of these

will uh end uh dying anyway so they are actually all ephemeral in a in a uh in a certain sense so why don't we we solve it in uh with more planned ephemerality so uh we go back to Genesis uh so uh emary or our this approach for uh testet which automatically goes back to Genesis rolls everything back to Genesis right now it's every week but it can be any given period so eme itself is a name of a test net which is running for well a year almost a year now it will be December in a it was in December last year we started first iteration and so yeah the the test net resets back to

Genesis uh which means all of the faucets are full again all of the validators are clean and stable again uh all of the the state is gone so I mean it's just few gigabytes for the for the whole test net again uh while maintaining the same single infrastructure because if we have like Hol K gly spinning up the new test net there needs to be I don't know infura and all of these big providers need to need to switch the the spin up new notes and start a new infrastructure and FM is achieving this with the same infrastructure the same B explorers the same notes uh just resenting resetting the network um and that means that the faucets can be very generous you can

just waste it because you know they will get it back in a few days um and uh we can ensure that there will be always finality because in the period when the test is running um with the enough valat in the Genesis there is there is not enough time for somebody to uh use all this uh free eat to overtake the secure majority so yeah that's how it looks today we have the iteration uh 101 already uh before it was the iterations like one and two days so that's why there is more than 50 of them but it's been yeah almost a year and uh yeah there are some some uh resources but I will uh show the link soon so right now we have the weekly reset and uh uh

currently the The testet Works in a way that it's mostly handled by um scripts it's uh um It's A bash script which is a reference implementation of the way how the the Genesis is generated and uh the the network reseted um every week uh after the reset uh it also deploys contracts which are some basic Primitives that you need uh on the network So like um uh to save uh Etc and um all of this is specified as some general uh General uh technology in its EIP which is currently in the review uh around the general road map we've been

yeah we took we've done such a path since the beginning since the initial proposal we are right now uh in the in the phase of uh client implementation and uh and wider discussion with client teams and yeah so it's in the EAP 6916 that's a specification of well not just emary but generally technology kind of test net which allows this kind of reset uh um and uh so uh the the EIP specifies uh two features two functions one is Genesis function uh which is uh deterministic de generation of the Genesis because which with each reset the network actually needs to create a new genesis it's not R uh resting back to the same one but to iteration to a

new uh incremented value values in a new genesis uh this is necessary to uh well keep track of the historical networks to be able to protect from replay attacks uh which would be otherwise possible so uh basically the the main part of the network is to be able to predict what's H what will be the next iteration the Next Generation uh and it's um it's actually pretty straightforward uh the main thing is the time stamp of the Genesis and the chain ID uh so uh if we know the period right now it's one week and you know the uh the previous time stamp you are able to calculate when the other Genesis after each week is supposed to happen

and each of it is iterated the chain ID is iterated just by one so um yeah the number of CH grows and um the Genesis always time stamp the this time when the Genesis occurs when when the network starts uh of course like just uh adding the period and uh yeah and yeah one important Point here is that so this uh approach that we that we describe in the EIP is something which can be implemented in clients which can be done in you know the go ethereum Aragon in uh lighthouse in Nimbus and each of the clients themselves uh however it's uh fully backwards compatible or it's compatible with the same uh implementation in the scripts so right

now the network is mostly running just on B scripts but the client which implements the same behavior as the script can just you know running the same network and uh uh continue following the same FM Network so yeah here you can uh read all the details in the um in the EIP uh when you look into the authors I just want to give shout out to Remy P here uh the Coors of the EAP because actually so when the when the project started when the initial ideas were gathered like a year ago at Defcon Defcon in bugata uh the idea was to actually dedicate to stakers we call it stakers test that because that was the main uh main problem at time with gly not being able to provide eat for

stakers and also uh make it very easy to just spin a note and then uh uh change it to main ad so um uh folks from E Staker were very helpful in the uh in the initial phase of the test net and uh uh well year later today we have um implementations in clients happening so uh so far loadstar has implementation which is almost done it has the main PR merch and it's basically ready and you can run it together with the uh with the other clients which are just using the scripts uh with get red and Lighthouse clients there there's also implementation happening it's in progress It's uh uh it's there are also like protypes which

are not merged in clients maybe don't have PRS but they are uh uh you can you know run the fork or uh contribute to these and also depth notes so like uh the thing is that again this can be either client or some external internal uh um Dev tooling some some devops tooling handling uh uh how the node behaves so it can be dep node or some other manager uh which uh which is able to handle your uh uh your system to to restart a note when it's supposed to so it's also being implemented in depth note as a as a separate package for fmal test Nets and so yeah right now based on the feedback from client implementers from people working on the actual uh

client code we are just geing some details which need to be uh smooth out in the the EIP specs uh but it's that's that's mostly done done uh but we are still we still need more tooling support like well the D node and uh and um uh other tools which are normally not counting on uh like changing every every iteration uh and need also either external script or implementation in themselves and uh yeah and the next step would be to push this to all Cs and have a wider discussion across client teams because some are aware but it wasn't brought up directly on ACD yet and uh you can use it today so yeah as I showed before I mean it's there it's running so even if you don't uh uh run like the the

modified version of the client you can use it because you can just you know add it to your to your wallet you can just uh connect to RPC there are multiple public RPC providers and by using it whether as a de developer or a Staker or running a note you can find issues provide feedback uh it's uh something very very helpful if you find any Miss Missing infrastructure that you would uh request or provide or help with all of this tooling we would be very much Happy so um it's especially useful if you want to do any form of of shortterm short-term tests so like if you are a developer learning solidity and you're going to do hello world and then you're going to do like basic calculator like

you know the the basic sort of contracts that you deploy to instead of of to uh gly or holeski instead of like bloating their state you can just put it on FM it's going to be the G going to be in a week but you don't your hello world contract doesn't have to be there forever so uh just uh use it for uh infrastructure that you don't need next week and also for a validator if you just want to try how the validator setup looks like and what you need to do how to generate the keys and uh and connect it to the network you can use uh feary uh you can run the validator for a few days uh then it resets and you need to do the deposit again uh you will also get uh reimbursed uh at the end of the

period you you you uh in the next period you get your test ether back actually uh uh but uh validators uh currently need to need to be yeah run only for a few days but it should be enough if you just want to do some some simple tests and yeah it will be very fast will be very easy because well the weak old network has really like few megabytes few gigabytes it's going to sync like this so yeah you can you can run it on a small machine you can easily test it out maybe even if you don't have a uh a you know big proper machine for a main at heavy full node you can just play with this and it will be much lighter than sepolia which is running for one and a half year or or Hol which has ton of validators

yeah H you can break anything yeah if you manage to break something we will be very happy so please join our Matrix Channel and uh let us know about what you manag to break what you are missing issues that you find uh you can find all of these resources in .ev which is the landing page where you can add it to your metamask and find all the details and is the Matrix Group you can you can uh join us at this QR code if you're interested in joining the community and uh chatting with contributors about aary uh and we have meet up on Thursday if you'd like to meet us uh people working on F the F Community contributors um uh join us on Thursday at 5: in a restaurant which is

nearby here you can find it on the the Twitter or in the The Matrix channel uh it's uh it's uh yeah being there so yeah I'm not sure if I have extra time to to uh take some questions but I guess that's it yeah thank you so much yeah thanks everyone oh I get some stickers if you stop by I will have some aary stickers for you any any questions from the audience here it was quick yeah thank you so much all right thank you Mario yeah thanks a lot good