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
As you can see, it is the loop we can travel with _links.prev.href infinitely.
This wrong cursor pagination is available on all endpoints, not only on /ledgers.
What did you expect to see?
We expected the cursor pagination to allow us to navigate back to the previous ledger records accurately.
What did you see instead?
The cursor does not correctly navigate to the previous records. Specifically, when trying to go back using the links.prev.href from a desc order page, it does not return to the correct previous page. Instead, it goes back to the starting point or does not navigate correctly through the ledger records.
Hathoriel
changed the title
Cursor Pagination Issue on Stellar Horizon Server v2.26.1
Cursor Pagination Issue on Stellar Horizon Server v2.26.1 (also v2.28.1)
Feb 16, 2024
What version are you using?
We are currently using Horizon Server version 2.26.1 on our node. The public Horizon server is on version 2.28.1. Both servers have same issue.
What did you do?
We observed an issue with cursor-based pagination on our Horizon instance. For replication, you can follow these steps:
An example from the public Horizon server that illustrates the expected behavior:
As you can see, it is the loop we can travel with _links.prev.href infinitely.
This wrong cursor pagination is available on all endpoints, not only on /ledgers.
What did you expect to see?
We expected the cursor pagination to allow us to navigate back to the previous ledger records accurately.
What did you see instead?
The cursor does not correctly navigate to the previous records. Specifically, when trying to go back using the
links.prev.href
from adesc
order page, it does not return to the correct previous page. Instead, it goes back to the starting point or does not navigate correctly through the ledger records.On the public - https://horizon.stellar.org/ is version 2.28.1
On our node is version 2.26.1 https://01-gravelines-068-02.rpc.tatum.io/
The cursor is not working as expected. When I am here:
https://horizon.stellar.org/ledgers?cursor=216445057270546432&limit=10&order=asc
And I click here: https://horizon.stellar.org/ledgers?cursor=216445061565513728&limit=10&order=desc
And then again, I click on the
links.prev.href
, I get: https://horizon.stellar.org/ledgers?cursor=216445057270546432&limit=10&order=ascBut it should give me the previous ledger.
The text was updated successfully, but these errors were encountered: