IntersectMBO / IntersectMBO/formal-ledger-specifications
Reconcile interfaces exposed by ledger spec and used by consensus spec
- Dominant language
- Agda
- Stars
- 52
- Forks
- 20
- Avg merge
- 6d 14h
- Merged PRs (30d)
- 7
Description
Currently, the interface exposed by the ledger spec for consumption of the consensus spec is the following:
```agda
record LedgerInterface : Set₁ where
field
Block Slot BBodyEnv BBodyState NewEpochState PParams : Set
getPParams : NewEpochState → PParams
_⊢_⇀⦇_,BBODY⦈_ : BBodyEnv → BBodyState → Block → BBodyState → Set
_⊢_⇀⦇_,TICK⦈_ : ⊤ → NewEpochState → Slot → NewEpochState → Set
```
However, the interface expected (and used) by the consensus spec is the following:
```agda
PoolDelegatedStake = KeyHashˢ ⇀ (Coin × KeyHashᵛ)
record LedgerInterface : Type₁ where
field
NewEpochState : Type
getPParams : NewEpochState → PParams
getEpoch : NewEpochState → Epoch
getPoolDelegatedStake : NewEpochState → PoolDelegatedStake
adoptGenesisDelegs : NewEpochState → Slot → NewEpochState
_⊢_⇀⦇_,NEWEPOCH⦈_ : ⊤ → NewEpochState → Epoch → NewEpochState → Type
```
It's very important to resolve these discrepancies between the above interfaces.
Contributor guide
Assessment
This issue has not been assessed yet.