nomos-specs/da/common.py
Daniel Sanchez 9a54d90d14
Da specs main structure (#70)
* Added da encoder pipeline draft

* Remove unnecessary method

* Added verifier module and blob type

* Fill verifier skeleton

* Add comments on implementation, remove unnecessary intermediary method

* Added dispersal skeleton

* Added test modules for dispersal and verifier

* Added test modules for encoder, implemented basic test

* Added missing test cases

* Added missing calls to encode method

* Use single megabyte test in encoder

* Added basic testcases for dispersal

* Added basic testcases for verifier

* Remove duplicated column proofs from encoding schema

* Remove parameters from test functions in encoder

* Extract common types to common module

* Make test pass

* Remove node id dep from mixnet and fix columns access
2024-02-12 15:35:23 +01:00

39 lines
482 B
Python

from dataclasses import dataclass
from typing import List, Generator
from eth2spec.eip7594.mainnet import Bytes32
class NodeId(Bytes32):
pass
class Chunk(Bytes32):
pass
class Column(List[Chunk]):
pass
class Row(List[Chunk]):
pass
class ChunksMatrix(List[Row]):
def columns(self) -> Generator[List[Chunk], None, None]:
# TODO: yield columns
yield None
@dataclass
class Attestation:
pass
@dataclass
class Certificate:
pass