mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-22 22:34:45 +00:00
Add is_optimistic to eth/v1/node/syncing response (#3374)
## Issue Addressed As specified in the [Beacon Chain API specs](https://github.com/ethereum/beacon-APIs/blob/master/apis/node/syncing.yaml#L32-L35) we should return `is_optimistic` as part of the response to a query for the `eth/v1/node/syncing` endpoint. ## Proposed Changes Compute the optimistic status of the head and add it to the `SyncingData` response.
This commit is contained in:
@@ -552,6 +552,7 @@ pub struct VersionData {
|
||||
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
|
||||
pub struct SyncingData {
|
||||
pub is_syncing: bool,
|
||||
pub is_optimistic: bool,
|
||||
pub head_slot: Slot,
|
||||
pub sync_distance: Slot,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user