This commit is contained in:
Etan Kissling 2022-07-15 13:45:34 +02:00
parent 88206117c6
commit de15971ae8
No known key found for this signature in database
GPG Key ID: B21DA824C5A3D03D
2 changed files with 8 additions and 8 deletions

View File

@ -204,13 +204,6 @@ def get_safety_threshold(store: LightClientStore) -> uint64:
) // 2
```
### `compute_sync_committee_period_at_slot`
```python
def compute_sync_committee_period_at_slot(slot: Slot) -> uint64:
return compute_sync_committee_period(compute_epoch_at_slot(slot))
```
### `get_subtree_index`
```python
@ -218,6 +211,13 @@ def get_subtree_index(generalized_index: GeneralizedIndex) -> uint64:
return uint64(generalized_index % 2**(floorlog2(generalized_index)))
```
### `compute_sync_committee_period_at_slot`
```python
def compute_sync_committee_period_at_slot(slot: Slot) -> uint64:
return compute_sync_committee_period(compute_epoch_at_slot(slot))
```
## Light client initialization
A light client maintains its state in a `store` object of type `LightClientStore`. `initialize_light_client_store` initializes a new `store` with a received `LightClientBootstrap` derived from a given `trusted_block_root`.

View File

@ -19,7 +19,7 @@ An SSZ-snappy encoded `bootstrap` object of type `LightClientBootstrap` to initi
The steps to execute in sequence.
#### `checks` execution step
#### Checks to run after each step
Each step includes checks to verify the expected impact on the `store` object.