Closed aemonm closed 1 year ago
👍
The spec says:
If the server has any more results available than it returns (the number it returns is less than or equal to the requested/default/maximum limit) then the server will include a link to the next set of results.
so yes it should be le
It seems like the limit should be enforced as "less than or equal to" and not "less than"
For example,
TIPG_MAX_FEATURES_PER_QUERY=50000
and a request ofcollections/public.slick_plus/items?limit=50000
, returns the error:{ "detail": [ { "loc": [ "query", "limit" ], "msg": "ensure this value is less than 50000", "type": "value_error.number.not_lt", "ctx": { "limit_value": 50000 } } ] }
Possibly limit check is defined here: https://github.com/developmentseed/tipg/blob/be04e608dcaccd408e638845e117506a47f64fda/tipg/factory.py#L785And this comment makes me think it should be treated as
lte
and notlt
. https://github.com/developmentseed/tipg/blob/be04e608dcaccd408e638845e117506a47f64fda/tipg/collections.py#L751