Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

connections: query results that exceed max_page_size do not set hasNextPage to true #659

Closed
blevine opened this issue Apr 5, 2017 · 2 comments

Comments

@blevine
Copy link

blevine commented Apr 5, 2017

This might be expected behavior. If so, feel free to close this issue.

If I issue a query that includes a connection field and do not specify any paging arguments (first, last, etc.), this translates into a "get all" query. If the results for that connection field exceeds max_page_size, then the result set will be truncated. However, the hasNextPage field of pageInfo remains false. hasNextPage is set correctly only if paging arguments are included in the query. This means that, without including paging arguments, there's no way for the caller to know that his query has been truncated.

I suppose you could argue that the caller should have been including paging arguments in the first place.

@blevine
Copy link
Author

blevine commented Apr 6, 2017

Looks like this is related to #656 which is due to graphql/graphql-relay-js#58

@rmosolgo
Copy link
Owner

It sounds like this behavior is spec-compliant, right?

I'd be happy to support behavior this behavior but only if:

  • Someone else implements it, and it's not the default (that is, default behavior is spec-compliant)
  • This behavior becomes part of the Relay spec

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants