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

API with custom selection set to include nested lists does not have next token #3128

Closed
lawmicha opened this issue Aug 8, 2023 · 3 comments
Assignees
Labels
api Issues related to the API category bug Something isn't working documentation Documentation improvements

Comments

@lawmicha
Copy link
Contributor

lawmicha commented Aug 8, 2023

Describe the bug

func testModelWithIncludedHasMany() {
let expectedSelectionSet =
"""
id
content
createdAt
draft
rating
status
title
updatedAt
__typename
comments {
items {
id
content
createdAt
post {
id
__typename
}
__typename
}
}
"""

Should have nextToken in the request that includes a nested list. This means the nested list won't have the capability to determine hasNextPage accurately

Steps To Reproduce

Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

Expected behavior

TBD

Amplify Framework Version

TBD

Amplify Categories

API

Dependency manager

Swift PM

Swift version

TBD

CLI version

TBD

Xcode version

TBD

Relevant log output

<details>
<summary>Log Messages</summary>


INSERT LOG MESSAGES HERE
```

Is this a regression?

No

Regression additional context

No response

Platforms

No response

OS Version

TBD

Device

TBD

Specific to simulators

No response

Additional context

No response

@github-actions
Copy link
Contributor

github-actions bot commented Aug 8, 2023

This issue was opened by a maintainer of this repository; updates will be posted here. If you are also experiencing this issue, please comment here with any relevant information so that we're aware and can prioritize accordingly.

@lawmicha lawmicha added bug Something isn't working api Issues related to the API category labels Aug 10, 2023
@lawmicha
Copy link
Contributor Author

This was discussed in the team, once we migrate the docs from https://docs.amplify.aws/cli/migration/lazy-load-custom-selection-set/ to the main documentation page, make sure to document that custom selection sets in API when including the nested associated data for has-many does not have pagination support

@lawmicha lawmicha added the documentation Documentation improvements label Aug 25, 2023
@lawmicha lawmicha self-assigned this Aug 25, 2023
@lawmicha
Copy link
Contributor Author

lawmicha commented Sep 1, 2023

We won't be adding nextToken since pagination won't work using this data when it is nested, related docs aws-amplify/docs#5822

@lawmicha lawmicha closed this as completed Sep 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Issues related to the API category bug Something isn't working documentation Documentation improvements
Projects
None yet
Development

No branches or pull requests

1 participant