You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When calling the list_organizational_units_for_parent operation, there is an inconsistent result returned versus the CLI.
Despite only having a single OU listed under the parent, the results from boto3 need to be paginated in order to retrieve the expected child OU details.
The same call through the CLI requires no pagination.
Expected Behavior
When there are fewer results than the page size limit, pagination should not be required.
Current Behavior
Organization Structure:
Root
| - Parent
| - - Child
In trying to get the Id of the Child Organization Unit, pagination is required on the list_organizational_units_for_parent operation using the Parent Organisation Unit Id
Reproduction Steps
Organization Structure:
Root
| - Parent
| - - Child
In trying to get the Id of the Child Organization Unit, pagination is required on the list_organizational_units_for_parent operation using the Parent Organisation Unit Id
Possible Solution
No response
Additional Information/Context
No response
SDK version used
1.34.79
Environment details (OS name and version, etc.)
Amazon Linux 2, Python 3.9
The text was updated successfully, but these errors were encountered:
The AWS CLI handles server-side pagination automatically, so it will continue to fetch results when there are more to return. Boto3 paginators enable this behavior as well.
Without automatic pagination the NextToken is required to fetch additional results, as described in the list_organizational_units_for_parent command documentation:
Always check the NextToken response parameter for a null value when calling a List* operation. These operations can occasionally return an empty set of results even when there are more results available. The NextToken response parameter value is null only when there are no more results to display.
Hi @tim-finnigan,
Thanks for coming back on this.
We did use the Paginator to get around this issue. It's just unusual behaviour that with a single OU, there are no results returned without pagination.
I think this was also behaviour that changed. We had this code in use since 2022 (albeit accessed infrequently) and now requires pagination.
Thanks for your time, @holdcrop
Describe the bug
When calling the list_organizational_units_for_parent operation, there is an inconsistent result returned versus the CLI.
Despite only having a single OU listed under the parent, the results from boto3 need to be paginated in order to retrieve the expected child OU details.
The same call through the CLI requires no pagination.
Expected Behavior
When there are fewer results than the page size limit, pagination should not be required.
Current Behavior
Organization Structure:
| - Parent
| - - Child
In trying to get the Id of the Child Organization Unit, pagination is required on the list_organizational_units_for_parent operation using the Parent Organisation Unit Id
Reproduction Steps
Organization Structure:
| - Parent
| - - Child
In trying to get the Id of the Child Organization Unit, pagination is required on the list_organizational_units_for_parent operation using the Parent Organisation Unit Id
Possible Solution
No response
Additional Information/Context
No response
SDK version used
1.34.79
Environment details (OS name and version, etc.)
Amazon Linux 2, Python 3.9
The text was updated successfully, but these errors were encountered: