Technical learnings from turning a live L1 to an L2
ETHCC 7 · 10 Jul 2024 · 27:52
Marek Olszewski, co-founder of Celo, shares what his team has learned since proposing to move Celo from an L1 to an Ethereum L2, now reflected in the Dango testnet launched just before EthCC. He describes carrying over features such as fee abstraction, stablecoin gas payments, sending money to phone numbers and automatic public goods funding. His lessons include using an existing L2 stack, with Celo choosing the OP Stack for Ethereum alignment, licensing and price-sensitive data costs, and embracing Ethereum by keeping a small patch set on top of Geth. He argues EVM L1s should become L2s.
Speakers
Topics
From ETHCC 7, hosted by Ethereum France.
Transcript
Okay, perfect, yes. Okay everyone. It's amazing to be here. Um thanks so much for coming out. I see that some people are still stuck at the uh immigration line, but they'll make it here eventually. Um yeah, my name is Marikoshewski, I'm one of the co-founders of Cello. Uh and today we're gonna be talking about Cello's uh transition from an L1 to an L two, um, really talking about the learnings um from kind of this journey uh that we started last year. Uh and if you like kind of the format of this talk, if you have any questions or anything, you definitely come find me afterwards or um find me on Twitter at Marik underscore.
Okay, so um at ECC last year, I was on stage um talking about kind of this really ambitious uh proposal that we made to transition Cello from an L1 to an L two. I think we were the first major L1 to really kind of make this proposal. Uh I almost wore that t-shirt today and then realized oh shit, maybe I shouldn't. Um and it was really exciting back then, right? I think maybe you heard it back then. Um the whole Sello community was very enthusiastic about it, but the whole Ethereum community was also very enthusiastic and very welcoming. Um and shortly afterwards uh we ratified the proposal uh through an on-chain governance vote.
And we've been really busy working on this uh transition ever since. Uh and fast forward to this week uh and this ECC, uh just a few days ago, we launched, just ahead of ECC, um the Dango L2 test net, uh which is really kind of the uh culmination of all of this work over this last year, preparing Cello for this very, very ambitious transformation. And so one way to think about Cello, and as you can see, I like emojis, I like explaining things in emojis, and so you'll see a lot of emojis in this talk. But one way to think about Cello is kind of the, or this test net, I should say, is this best of uh all of Cello kind of distilled into an L2 product.
We've got the um fee abstraction support that Cello supports. Uh that's the little uh gas uh station emoji. Uh you can pay for gas with tokens on Cello, including uh native USCC, native USDT. Uh so all that has kind of made it into Dango. Uh social Connect uh and other uh code that we've actually moved into into Solidity is also supported, so you can send money to phone numbers in Dango, and then also uh the ultra green money uh piece of Cello, this um really interesting way of funding public goods automatically, auto uh PFGs we call it, um, funding where we take a portion of transaction fees and we go do things like, for example, buy carbon offsets programmatically and retire them to make Cello a carbon neutral chain. Uh we've taken all of these things and we've kind of put them into Dango.
Luckily, Dango has an emoji. If you're if you're curious, actually, Dango's are these kind of really nice uh Japanese desserts. Um all of our test nets are named after desserts. Uh, and over time, we got a little smarter and we started picking uh desserts that have emojis. Uh, it makes my life a lot easier for these talks. Uh but yeah, all of those features are now available in in Django, and it's it's really, really exciting. Um, and all of this is now happening in this kind of broader trend uh that you've probably kind of heard about, which is kind of Ethereum becoming kind of the settlement layer of Web3. You know, this is something that Justin Drake talks a lot about.
Um, you know, this is something that's really exciting to us, right? I think we've actually started our journey uh way back when in Ethereum, and so this is kind of a bit of a coming home uh moment for us. But um, you know, we've always been excited about the future of Ethereum, and we're really excited about this future of Ethereum. Um, and we really hope that Cello can be this kind of case study uh for other L1s to kind of follow suit. You know, we in my mind, success would be not just Cello becoming an L2, but you know, the avalanches, the the Gnosis chains, the phantoms, anything that's EVM compatible, I think, you know, really has no business being uh an all-tell one anymore. It really should transition to becoming an L2.
And we really hope that Cello can be a really nice case study for others to follow. But there's obviously a but um it's not that easy. Um, you know, this was the only emoji I could find to convey the concept of something that is really hard, uh, this big rock. Um transitioning to an L2 uh is certainly very, very hard. Um, you know, a lot of people think, oh, it's just a hard fork, right? In our case, we're not talking about launching a new L2 and calling it Cello. We're literally talking about uh upgrading Cello so that it becomes an L2 and all of its state uh is preserved, so that application developers don't have to really do uh that much, certainly not end user application developers. Um, and that is very, very difficult.
That is uh not just any hard fork, that is what we like to call a hard hard fork. Um, and so that means two rocks and a fork. Um, really, really hard. Um, and you might be asking, well, why is it so hard? I mean, it's just you know a network, just uh strap on a native bridge and add some settlement to Ethereum, it should be easy, right? But I think it's it's hard in large part because you know, to kind of borrow another emoji and to use another emoji metaphor. It's hard because you know, Cello's at cruising altitude.
It's been around for four years, it's been cruising in the air for four years. It has uh a ton of users uh inside that fuselage, uh, and we're literally rebuilding this plane, kind of taking engines off, taking them apart, kind of putting them on different parts of the plane. We're doing all of this while it is at cruising altitude, and that's really really really difficult. Um and just to give you a sense of you know how many uh passengers inside the fuselage, um, you know, Cello, if you go to token terminal and you look at kind of the the daily active user numbers. Uh Cello is frequently a top 10 chain, according to token terminal.
Um I think on this particular day that this tweet came out just a few weeks ago, Cello, uh, if it were an L2, would have been actually a top two L2 by daily active users. So there is a lot of users. Uh, and that trend is only increasing. So this is the number of uh monthly active users over time. Um you can see that around a year ago, things really started to kind of pick up again. Uh, we've surpassed the peaks of the last bull market by a long shot, and already the numbers for July look like they're gonna surpass this last um kind of bar here on the far right, uh, which was for the month of June. And you can see that we've kind of crossed already two million monthly active users, which is uh a really amazing number.
Um people kind of are curious what's driving this. Uh and I would say kind of uh a couple of things, uh, but you know, primarily wallets that are focusing on uh P2P use cases. So we've got Valora, but we've also got Minipay that launched more recently. Uh MiniPay is a stablecoin only wallet that supports C USD native USDC that's now deployed on Cello, uh USDT, native USDT that's now deployed on Cello. And it's a really a wonderful experience that leverages really the best of all of Cello. You can send all of these assets without having to have a volatile asset to pay for gas.
You can send it to phone numbers in your contact list. And people are starting to use this in large numbers, in large part because Minipay is built inside Opera Mini, uh, which is a browser that has uh 500 million installs, 100 million monthly active users, primarily in in Africa. Opera, of course, is a big public company that's traded on the NASDAQ. Um, and you know, they're really putting a lot of energy behind making this really big, and so definitely keep an eye out for this. Um, I think you guys are gonna see a lot more from them. And all of this is creating kind of this voracious appetite for stablecoin demand on Cello.
I mentioned kind of USDT and USDC launched recently. Um, their circulating supplies keep growing, and we we're frequently ranked number one on token terminal for uh for stable coin circulation supply growth. Uh DeFi Lama also was saying that in the last week we were growing uh a crap ton. Uh that number is actually even higher now. I think there's 220 two million 225 million. Last I checked a few days ago, it might be more by now. Um, and all of this is creating just a record amount of stablecoin volume, um, just under one billion dollars worth of stablecoin volume last month. Um that is a lot of transactions, that is a lot of value that's being moved around.
And as you can imagine, you know, upgrading an L1 to an L2 is uh is a pretty tricky endeavor. And when you have to do it with you know these sums of money uh that are relying on the platform to execute well, um, that puts a lot of pressure on us. You know, obviously I'm in conference mode now wearing swag and everything, but you know, we're we're a really buttoned-up operation, and we're really making sure that this is a really um smooth experience for for our builders and for all of the users who are gonna be um using Cello when when this upgrade happens. Okay, so Dango again is kind of the first step towards um this really thoughtful and intentional upgrade.
Um and you know, coming back to the talk, the title of this talk, we we wanted to spend just a little bit of time talking about kind of our learnings for um uh that we've kind of learned over this last year to share again with others who might be considering this, um, and really to encourage other people who who might be considering this. Because again, we're very, very excited about this future of Ethereum becoming the settlement layer of Web3. And so we're gonna do five learnings, so that's not stop, that's the number five, uh, five digits. Uh so let's go through them.
So, learning number one. Uh, learning number one is to use an existing L2 stack. So early on, we were excited about building our own L2 stack, right? Um, you know, we have the technical experience to be able to do it. You know, I think it's an interesting academic problem that you know is is easy to kind of get excited about. But you know, the more we thought about it, the more we realized, you know, our goal is not just to make uh Celex succeed, but also to make Ethereum succeed as a whole, and adding an extra stack to what already is you know quite a crowded space. It's already causing quite a bit of fragmentation, you know, we thought was was probably not the best thing for for Ethereum uh at this time.
Uh and so we ended up choosing to uh to build on top of an existing stack. Uh we actually got a lot of inbound after that announcement uh last year, which was very humbling. Uh and we spent honestly a very large amount of time spinning up test nets, looking at the code, talking with the teams, really doing this decision justice. Um just, you know, and I can't thank all of those teams enough for for talking to us, you know, all of the major stacks. You know, they really spent uh a really good amount of time with us and we're very, very appreciative.
Um and and so certainly if you're looking to launch your own L2, uh, and certainly if you're looking to migrate an L1 to an L2, highly recommend going through that same process. Um it's it's definitely very, very worthwhile. Um ultimately we picked uh the OP stack in large part because we we love their Ethereum alignment, we love their very permissive license. Um we're very mission-lined, uh both on the public goods front, but also on kind of the UBI front with with world chain uh launching in in the OP stack. So there was just a lot of synergies, a lot of alignment.
Um and then on the data availability front, we are very, very um price sensitive. A lot of those use cases that I showed that are driving all of this uh that volume, uh they're all you know, micropayments in emerging markets, P2P payments amongst people using you know things like Valora and MiniPay. Uh folks in markets where um people are very, very price sensitive. And while certainly um blob space, you know, is is relatively cheap right now. Uh we've seen some volatility, uh, of course, you know, we expect a lot more to come, um, and we want to make sure that uh we can maintain really, really cheap gas fees for those users for the long term, um, in a way that's very, very Ethereum aligned.
And again, so we really liked how you know eigen DA is being run by uh Ethereum validators and you know is is protected with ETH uh staked D ETH. Um the one really nice uh I think outcome of picking OP stack, um, just very serendipitous, uh, is I think that you know many others think the same way, and you know, OP stack is kind of on fire right now. Um you guys maybe seen this recently, you know, 57, just under 57% of all L2 throughput is being powered by the super chain right now. Uh and if you look at uh all OP stack chains, you know, we're talking about just under 74% of all L2 throughput is um powered by OP stack.
So this is clearly where the energy is. Um again, you know, we we made our decision before uh the numbers kind of swung uh so heavily in this direction, but it's very, I would say validating, you know, to have picked something that that now is really, really, really taking off. So we're really excited about that. Okay, learning number two. Um, embrace Ethereum. So after we made our announcement, we we saw from other L1s kind of claims that you know we too might become an L2. Why not?
Uh, after all, isn't an L2 just like uh a native bridge or something? Or maybe we can be an L2 to Ethereum. And then I heard some people saying an Ethereum can be an L2 to us at the same time, whatever that means, right? Um, you know, I think maybe this started to become kind of a popular trend, but I think few people had the um uh conviction to really kind of go and take, you know, or the to take this leap of faith to really go and make this transition. And and and to those people, I encourage you to do it.
I think it's worth it. You know, I think being an L2 is more than just a native bridge, it's really settling to Ethereum. Uh and I think ultimately if you're an EVM chain today, um then you know I think ultimately it just makes no sense again to be uh an alt-L1. Um before Ethereum had a scaling roadmap with multiple chains, you know, I think that made total sense. That's why, you know, four and a bit years ago we launched as an alt-L1. Um, but now in in this era, uh certainly again if you're EBM uh focused, it just doesn't seem to make sense. So embrace it.
Um and and then our other kind of more practical, maybe technical advice to folks is really to kind of distill the best of your protocol and kind of create and put it into a patch queue on top of Geth. Um so that's ultimately what we did, inspired in large part um by kind of OP's approach. There's really a lot of nicety, I should say, with kind of that approach where you you basically try to have a just this tiny little diff uh on top of Geth so that as Geth uh continues to evolve, you can keep merging upstream changes. You can really kind of challenges you to be as Ethereum compatible as possible.
Um and I think ultimately it just creates uh it makes everything so much easier. And so that's what we did. You know, all of those things that I talked about, the the fee abstraction, the uh ultra green money, social connect, uh other things like this kind of native token duality where you can use Cello as a native token but also as an ERC20 token, all of that we've kind of distilled into a really nice uh very small um patch queue on top of OPGeth in our case. Um and and we we we really like this approach. And again, this is in large part possible because of um OP's approach of using Canon to compile kind of Go code into MIPS and then to be able to use that MIPS code with their with their fault proofs um through their MIPS emulator uh on L1.
Um this is just really, really a lovely uh mechanism that uh just also meant that we could uh code all of our um kind of unique features and and have them be uh automatically supported by Canon. So highly recommend others do this as well. Okay, learning number three. This is where the emojis start getting funkier and funkier. Um migrate your chain data. Um so what is this emoji showing? This is an eagle that's migrating and it's carrying a floppy disk, which is representing our chain data.
So when we started, we we thought about um really porting everything in cello into into OPGeth and into the OP stack, including um all legacy transactions and all transactions that we could make obsolete in the future. Um all of the differences that we have from Ethereum, which of which there's quite a lot, um, you know, porting all of that. But but that kind of goes against this advice that I just shared a second ago, which is to try to create this really small um kind of diff from geth. And so the solution is actually an elegant one.
Uh it's just migrate your chain data. So you know, in the future, when we do this upgrade, um, and you know, also showing what we did with the Dango uh upgrade, um, you know, we've got our chain, it's humming along, uh, creating L1 blocks. Um at some block height. Um, we migrate our chain data to effectively rewrite it to be compatible with the format of Geth. Uh so in our case, we have slightly different block uh formats, we have slightly different header formats. We launched um when Ethereum was still proof of work based, so we removed all of the proof of work headers.
Um, effectively um removing all of those differences that we made and rewriting all our data in a fully compatible way, uh, so that when we kind of progress as an L2, all of that is again fully compatible with Geth, with OPG, and doesn't require kind of a big uh big diff from from Geth. And this migration, you know, you can imagine takes some time, but in order to minimize the downtime, the bulk of it can actually happen uh ahead of time in parallel while the chain is still producing blocks. So we can actually still do this in a way that creates very, very small amount of downtime.
Um so a lot of the work going into Dango was really getting good at doing this quickly, doing this reliably, uh, and and ultimately doing this in a way such that uh we can eliminate a lot of those differences uh from um from uh Ethereum that we kind of had in the past. And I imagine that you know many other L1s, you know, they've all have their kind of unique flavor, they all have some uh kind of niche that they're trying to target. They all you know probably have differences, and I encourage them again to kind of rewrite those differences rather than the code, rewrite the um the data that that the code is is manipulating into a format that's compatible with Ethereum, and I think that's the the good way to go. And this does mean, of course, that you might be querying an archive node uh on chain data um from you know a while ago that won't know how to respond to those requests because it won't have the code to, for example, trace legacy transactions or uh look at you know legacy headers or block contents.
And so this means that we actually have to uh proxy those requests to uh archive nodes that uh do understand how to do all that. Um and so this is a really elegant solution to being able to seamlessly support you know tracing and doing other RPC calls in archive nodes for kind of legacy block data. But doing it in a way that's fully opaque to the user. The user doesn't have to really know that this is happening behind the scenes.
And this is all inspired by kind of OP and what they did with Bedrock. And this is again a nice kind of benefit of OP stack and a nice outcome of us kind of picking that stack. And also a big reason why we picked that stack, because we knew that this would be a fairly big and complicated undertaking and this design is a really elegant one. Okay, learning number four. And so there's no emoji that shows four fingers, so I had to generate something that looks like an AI mangled hand. You guys all know, seen those mangled AI generated hands.
Learning number four is to rethink where your tokens live. So this is again on the theme of embracing Ethereum, but also to be uh compatible with OP stack and to really minimize the differences between what we need to support our our legacy features and the OP stack. Uh Cela will actually exist as a kind of sister token on Ethereum after this hard fork, uh, which is gonna be pretty exciting. So it's gonna be minted with the full supply, and then that full supply is gonna be moved uh fully into the native bridge at the time of the migration, um, so that if people want to um you know hold cello on Ethereum, uh they'll be able to just move their cello over using that native bridge to Ethereum where it'll be again a native token. So this is really exciting.
Again, we encourage others to kind of follow suit as well. I think again, this is just a really nice way of again embracing Ethereum. Okay, learning number five. For this, at least we had an emoji. Learning number five is to do lots of upgrades. So again, we have a lot of value that's being transacted on Cello, a lot of users on Cello. We want to make sure that this upgrade goes without a hitch, and our way of doing that is you know, obviously, beyond lots of audits and lots of work is to do lots of dry runs. We've upgraded our Alpha Horas network, or forks of it, I should say, many, many, many times.
And you know, the last time we did that, we kind of launched the Dango uh test net again. So Dango is a fork of the Alpha Horas test net. Again, I mentioned that all our test nets are named after delicious treats from around the world. So Alpha Horas are these amazing cookies from Argentina. And so Dango is a fork of Alpha Horas and then an upgrade of it. Um the idea for Django is to be somewhat of a short-lived uh test net that allows anybody who you know is really excited about about uh where cello is going to start experimenting with it, particularly the infrastructure providers. You know, we want the Infuras of the world, um, the uh chain links of the world, uh, all the major indexers, all to have experience with the code base with Django before we go and upgrade Alpha Horas, because when we upgrade Alpha Horas, we want all of those things to just work really quickly so that all builders who are building on top of Alpha Horas today don't have to go, oh, why did Chainlink stop working?
I'm trying to build a new DAP, and this is making it harder for me to actually build that DAP. So once all of those service providers are ready, we're gonna upgrade Alpha Horas. That's gonna be really exciting. Next, we have a test called Baklava that is kind of the closest to production uh network that we have that's kind of run by our whole community. This is gonna be our kind of big dry run. And if everything goes smooth there, we'll be ready to upgrade mainnet uh hopefully by the end of the year, knock on wood. A lot of that depends on obviously a lot of these uh infrastructure providers and ecosystem partners kind of supporting things. If you're not running a full node or an archive node, chances are you won't have to do anything other than maybe switch to uh an archive node or a full node that is um cello L2 uh compatible.
Um, you know, I think it still might take folks some time to kind of move to those RPC providers. Certainly it'll take RPC providers some time uh to upgrade, and then you know, obviously, some folks run their own nodes uh and they're gonna have to upgrade themselves as well. But anybody working um, you know, focusing on end users, um, you know, most wallets, most dApps that are really kind of focused on end users, they're not gonna have to do anything. Um, and you know, we're really excited about again making their lives easier, making this whole thing really smooth. Cool.
So maybe just to wrap up, you know, what should you be looking out for? I mean certainly if you're a builder and you're kind of interested in playing around, you know, check out the Dango Block Explorer. Block Scout was incredible. They they launched this like literally a day after we we launched Dango. Big big shout out big kudos to them. You can check it out at Sello dash Dango dot blockscout dot com. Really cool. Superbridge also super big shout out to them. They they launched um support for our native bridge on their testnet page really rapidly as well so you can check that out by testnets.superbridge dot app. If you want to you know test bridging something from Hillesky over to Dango definitely go there and check it out.
It's super super exciting. And you know start building you know we're gonna have a big presence at ETH Global as we always do. So if you're participating in the hackathon definitely come talk to us. Yeah we're really excited to meet with you and talk more about you know all this exciting work that we're doing. So yeah thank you so much. Do we have time for questions?
Related talks
- Celo Eclair Testnet: A Public Network Using SP1 and EigenDA
- Cheap transactions with Ethereum security
- State of Layer 2 - Sandeep Nailwal
- Speedrun Rollups: A Beginner's Guide to L2s, ZK, and WTF People Are Talking About
- Celo's L2 Proposal: Scaling Up the Tempo of Affordable Transactions - Marek Olszewski
- Ways of Scaling Ethereum: Offchain and Onchain
- Modular Rollup Theory Through the Lens of the OP Stack by Kelvin Fichter | Devcon Bogotá
- Scaling Ethereum with Rollups – John Adler
- What do we need to do to take Ethereum to the next Cerium users Ed Felton