You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
rs-sdk: keep a paged read's next page at or after the block of the page before it #6081
rs-sdk's paged queries continue by a key boundary only. Examples: ContractModerationEntriesPageQuery::after, ContractDocumentRemovalsPageQuery::after and ContractTeamActionsPageQuery::after in packages/rs-sdk/src/platform/contract_moderation.rs, and the document listings work the same way.
The SDK's default height tolerance lets a response trail the newest height seen by one block. So a full first page answered at height H can be followed by a page answered at H-1. That second page leaves out a row added at H that sorts after the first page's cursor, and a host can read an empty or short page there as the end of the list.
Proposal:
carry the verified height of the page before in an SDK-owned continuation;
read the next page with the existing read_not_older_than (platform/documents/contest_vote_state.rs), as the contest vote state pages already do.
FFI and mobile bindings would pass the continuation through as an opaque value, with no comparison or retry policy of their own. This makes paging monotonic without promising a single-block snapshot.
Activity