Events::oldest_event_count
and Events::oldest_id
don't make the difference to each other clear enough
#15617
Labels
C-Docs
An addition or correction to our documentation
S-Needs-Triage
This issue needs to be labelled
I am not certain if this is a docs issue, but I found this by looking at the source, not by encountering some bug. That is why for now I focused on how the API appears while there are more issues.
The methods
Events::oldest_event_count
andEvents::oldest_id
seem to do the same thing when looked at the docs or the source.Also the API itself is confusing. Instead of returning
usize
it should return anOption<EventId<E>>
because no oldest event might be available currently if the sequencesevents_b
andevents_a
are empty.As a side note, the implementation of
oldest_event_count
looks like that:When it should be clear that
self.events_b
as the more recent sequence cannot contain the oldest count.oldest_event_count
was added by [Merged by Bors] - Warning message for missing events #5730oldest_id
was added by [Merged by Bors] - Rework manual event iterator so we can actually name the type #5735The text was updated successfully, but these errors were encountered: