flow-go icon indicating copy to clipboard operation
flow-go copied to clipboard

[AN] Event streaming special value for height

Open devbugging opened this issue 11 months ago • 2 comments

Currently when subscribing to events if you provide a value of 0 as the start height that value is treated as latest height. This can be very confusing and lead to bugs since height 0 would probably often be confused as the first height on the network. The consequence this can have in services that monitor network is they mistakenly use 0 as first but miss a lot of events (trust me, I've burned myself like that). My suggestion is for special values used for heights to be set as maximum number of the type and then decreased by one for each new value: Max(UInt64)-X.

devbugging avatar Feb 29 '24 14:02 devbugging