Open PCunninghamML opened 9 months ago
Thanks for the report, and apologies for not getting back to you earlier.
I thought this was https://github.com/stac-utils/pgstac/issues/177 (which is very similar) but we have that deployed and are still seeing this issue. We'll look into it and will get back to you.
For reference, here's the pystac-client version:
import pystac_client
catalog = pystac_client.Client.open("[https://planetarycomputer.microsoft.com/api/stac/v1")](https://planetarycomputer.microsoft.com/api/stac/v1%22))
a = catalog.search(
collections="sentinel-1-rtc",
# limit=250,
bbox=[-128.787231445313, 22.917922936146, -63.7481689453125, 50.6250730634144],
# sortby=["properties.title"],
datetime="2020-01-01/2020-01-15"
)
b = catalog.search(
collections="sentinel-1-rtc",
# limit=250,
bbox=[-128.787231445313, 22.917922936146, -63.7481689453125, 50.6250730634144],
sortby=["title"],
datetime="2020-01-01/2020-01-15"
)
aa = a.item_collection()
bb = b.item_collection()
assert len(aa) == len(bb), (len(aa), len(bb))
That's giving 943 vs. 499
Similar/same issue reported on stac-fastapi: https://github.com/stac-utils/stac-fastapi/discussions/620#discussioncomment-7965235
Has the status on this issue changed? I noticed the linked stac-fastapi comment mentions the issue possibly originating in stac-utils/pgstac but I didn't see any open issues over there describing the same behavior.
No updates here yet. We'll make an issue on pgstac once we have a reproducer that's isolated to just it (if indeed that's where the problem is).
I'm running a search of Sentinel 1 RTC via URL which is filtered to roughly the lower 48 US states. I'm getting what appears to be a correct response that can be paged via next links to completion. However when sorting by title, the results of the second page are presented as the end of the dataset (# results less than limit param, no next link). I wouldn't think that adding a sort parameter ought to affect the number of features/items.
Searching "ALOS PALSAR Annual Mosaic" (alos-palsar-mosaic) with the same parameters and sorting appears to produce the expected results.
Thank you for your help.