# EPF5 Week 1: Kick-off :rocket:
## Week overview
- [X] Learned protocol architecture
- [X] Studied the Ethereum roadmap
- [X] Understood Consensus Layer
- [X] Reviewed EIP-7594 PeerDAS
- [X] Installed CL specs, ran tests
- [X] Watched EPF Study Group Videos
- [X] Explored PeerDAS issues and discussions
## Protocol architecture
I began with the Protocol Architecture Overview utilizing [epf.wiki](https://epf.wiki/) and EPF Study Group videos. Mentioned for myself that I am not familiar with Engine and Beacon APIs, primarily using JSON-RPC API for Execution Layer. My focus for PeerDAS will be the Consensus Layer. So, what I definetely need is CL specs.
[Protocol schema on epf.wiki](https://epf.wiki/wiki/protocol/img/protocol-overview.png)

## Ethereum roadmap and upgrade
[Vitalik Buterin: Ethereum roadmap on X](https://x.com/VitalikButerin/status/1741190491578810445)
[Ethereum.org roadmap](https://ethereum.org/en/roadmap/)
To understand the current state of the Ethereum and near future steps and plan my contribution, I learned the Ethereum roadmap. It includes several key upgrades aimed to enhance the network's scalability, resilience, and security.
### Dencun upgrade 2024
Ethereum adopted EIP-4844, commonly called proto-danksharding. This upgrade introduces type-3 transactions (blobs), bringing new opportunities and new complexity for Layer 2 networks to optimize how they settle to the base layer.
### Pectra upgrade Q1 2025
This upgrade is anticipated to bring further enhancements to the Ethereum network, building upon the foundation established by the Merge and Shanghai upgrades.

## Consensus Layer
PeerDAS is being implemented on the Consensus Layer. Therefore, I need to understand and likely operate CL clients. I watched a video from the EP Study Group and plan to attempt running a client locally.
The current state of **consensus clients**:
| Client | Lang | Team | Docs | Repo |
| -------- | -------- | -------- | -------- | -------- |
| Lighthouse | Rust | Sigma Prime | [Lighthouse Book](https://lighthouse-book.sigmaprime.io/) | [Github](https://github.com/sigp/lighthouse) |
| Lodestar | TypeScript | ChainSafe | [Lodestar Docs](https://chainsafe.github.io/lodestar/) | [Github](https://github.com/ChainSafe/lodestar/tree/v1.19.0) |
| Nimbus | Nim | Status | [Nimbus Guide](https://nimbus.guide/) | [Github](https://github.com/status-im/nimbus-eth2) |
| Prysm | Go | Offchain Labs | [Prysm Docs](https://docs.prylabs.network/docs/getting-started) | [Github](https://github.com/prysmaticlabs/prysm) |
| Teku | Java | ConsenSys | [Teku Docs](https://consensys.io/teku) | [Github](https://github.com/Consensys/teku) |
## Running CL Specs
I installed [CL specs](https://www.youtube.com/watch?v=ZDUfYJkTeYw). The installation process is in README.md or in the [EPF Study Group specs video](https://www.youtube.com/watch?v=_mb0LFJY8t0&list=PLvu3JfoGPg5nt45MNYEuExw17pbH9MB3p&index=7). I am using Python 3.12.
Set up your virtual environment:
```
python3 -m venv venv
```
You will find **venv** folder in the root of the specs.
Activate the environment:
```
. venv/bin/activate
```
Install dev dependencies:
```
make install_test && make pyspec
```
Go to the **./tests/core/pyspec** and run PeerDAS tests:
```
python -m pytest --preset=minimal eth2spec
```
Running a specific test:
```
python -m pytest --preset=minimal ./eth2spec/test/phase0/block_processing/test_process_attestation.py
```
The result is on the screenshot:

## PeerDAS (EIP-7594)
[EIP-7594: PeerDAS - Peer Data Availability Sampling](https://eips.ethereum.org/EIPS/eip-7594)
**PeerDAS** is a networking protocol that allows beacon nodes to perform data availability sampling (DAS) to ensure that blob data has been made available while downloading only a subset of the data.
**DAS** is a method of scaling data availability beyond the levels of EIP-4844. Nodes are not required to download all data, but they can still ensure that all of the data has been made available.
Providing additional data availability helps bring **scale** to Ethereum users in the context of rollups whose dominant bottleneck is layer 1 data availability.
Extanding blobs: one-dimensional erasure coding extension. A node can reconstruct the entire data matrix if it acquires at least 50% of all the columns. If a node has less than 50%, it can request the necessary columns from the peer nodes.
### ethresear. ch
- [PeerDAS – a simpler DAS approach using battle-tested p2p components](https://ethresear.ch/t/peerdas-a-simpler-das-approach-using-battle-tested-p2p-components/16541)
- [From 4844 to Danksharding: a path to scaling Ethereum DA](https://ethresear.ch/t/from-4844-to-danksharding-a-path-to-scaling-ethereum-da/18046)
- [SubnetDAS - an intermediate DAS approach](https://ethresear.ch/t/subnetdas-an-intermediate-das-approach/17169)
### Ethereum magicians
- [EIP-7594: PeerDAS - Peer Data Availability Sampling](https://ethereum-magicians.org/t/eip-7594-peerdas-peer-data-availability-sampling/18215)
- [PeerDAS breakout #1](https://ethereum-magicians.org/t/peerdas-breakout-1/20275)
## Weekly EPF Activity
- [EPF5 Kick-off](https://www.youtube.com/watch?v=XpZC_gAW4ag&t=3671s)
This call was welcoming, intoduction to the program, Q&A.
- [EPF5 Office Hours with Tim Beiko](https://www.youtube.com/watch?v=5L9UUCL7bzI)
Tim gave us an overview of Ethereum governance. We could also ask our questions about the program, the protocol.
[Ethereum Governance](https://ethereum.org/en/governance/)
- [ACDC - All Core Devs Call #135](https://github.com/ethereum/pm/issues/1069)
My first call felt like the devs were speaking Elphian. I'd seen calls before on YouTube, but this was the first time experiencing one live on Zoom.
## TODO
- [ ] Dive deep into PeerDAS and blobs
- [ ] Set up testnet light client
- [ ] Understand CL specs
- [ ] Discuss my potential contributions with mentors
- [ ] Investigate devnets (devnet1, peerdas-devnet-0)
## Glossary
| Term | Description |
| -------- | -------- |
| Electra | CL upgrade |
| Pectra | Prague-Electra upgrade. Scheduled for Q1 2025. |
| ePBS | Enshrined Proposer-Builder Separation: transparent and fair mechanism for block production. Addressing MEV Concerns. CL. |
| [Kurtosis](https://github.com/ethpandaops/ethereum-package) | Toolkit for running a multi-client Ethereum testnet for local dApp development, prototyping, and testing. |
| Stable containers | [EIP-7495](https://eips.ethereum.org/EIPS/eip-7495): New SSZ type to represent a flexible container with stable serialization and merkleization |
| [Attestations](https://ethereum.org/en/developers/docs/consensus-mechanisms/pos/attestations/) | A validator is expected to create, sign and broadcast an attestation during every epoch. The purpose of the attestation is to vote in favor of the validator's view of the chain. |
## Links
### CL
[Epf.wiki Consensys Layer](https://epf.wiki/#/wiki/CL/overview)
[EL/CL specs EPF Study group](https://www.youtube.com/watch?v=ZDUfYJkTeYw)
[DevCon Bogota: How to use CL specs](https://www.youtube.com/watch?v=ZDUfYJkTeYw)
[Bacon API](https://ethereum.github.io/beacon-APIs/#/)
### PeerDAS
[EIP-7594: PeerDAS - Peer Data Availability Sampling](https://eips.ethereum.org/EIPS/eip-7594)
[Data Availability on Ethereum.org](https://ethereum.org/en/developers/docs/data-availability/)
[DAS specs](https://github.com/ethereum/consensus-specs/blob/b4188829b32139916127827c64ba17c923e66c3c/specs/_features/eip7594/das-core.md)
[PeerDAS Breakout Room #1](https://www.youtube.com/watch?v=P86Dr9ABGeg&t=468s)
[Ethereum Magicians PeerDAS discussion](https://ethereum-magicians.org/t/eip-7594-peerdas-peer-data-availability-sampling/18215)