Skip to content

next_key not returning correctly when open deployments match limit #431

@cloud-j-luna

Description

@cloud-j-luna

Assign the support label to any support escalation issues

Describe the bug
There seems to be a pagination bug in the deployments endpoint, specifically the filtered request.
When 10 items are returned no next_key is returned, but if I do 20 (or any number other than 10) next_key is configured.

Note: there are precisely 10 open deployments.

To Reproduce

akash query deployment list \
  --owner akash10lq8uyfl52d6t467qmd58e7jzl9ecmvet2m57p \
  --limit 10

# Returns
...
pagination:
  next_key: null
  total: "10"
akash query deployment list \
  --owner akash10lq8uyfl52d6t467qmd58e7jzl9ecmvet2m57p \
  --limit 20

# Returns
...
pagination:
  next_key: wNDXdwECGBEAAhR/wH4RP6KbpddeBttD59IXy5xtmQgAAAAAAYR94w==
  total: "20"

Expected behavior
next_key should be provided if there are more items to return.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions