celestiaorg / celestiaorg/go-header

feat: introduce new type of error

Open
#157 2 comments 1 reaction 0 assignees View on GitHub
Dominant language
Go
Stars
21
Forks
33
Avg merge
5d 20h
Merged PRs (30d)
7

Description

After pruning is finished + backward sync is introduced, our ErrNoFound will have 2 meanings:
1) The Node is still syncing and hasn't synced to the requested height yet;
2) The node does not have this height and will not sync on it in the future;

As it will confuse us and users, we should agree and differentiate these two cases by introducing one more error for the first case -> `ErrNotSynced`.

cc @renaynay

Contributor guide

Open the contributing guide

Research direction

Start by locating the existing ErrNoFound definition and its call sites in the Go library. Trace how the two described conditions are currently reported, then confirm that the syncing case is distinguishable as ErrNotSynced while the missing-height case retains ErrNoFound.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
blockchain
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.