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
The below code attempts to list all groups in an identity domain. However, adding either attribute_sets or attributes will cause the response to indicate has_next_page == True and next_page to have a value even if the results are already complete.
importociconfig=oci.config.from_file("~/.oci/config", "DEFAULT")
tenancy_ocid=config["tenancy"]
# Get the domain endpointidentity_client=oci.identity.IdentityClient(config)
list_domains_response=identity_client.list_domains(tenancy_ocid)
domain01_endpoint=list_domains_response.data[0].url# Get the groupsidentity_domains_client=oci.identity_domains.IdentityDomainsClient(
config, domain01_endpoint
)
list_groups_response=identity_domains_client.list_groups(
# BUG: adding attribute_sets or attributes causes the `has_next_page` to be trueattribute_sets=["request"],
attributes="members,ocid",
)
print(list_groups_response.has_next_page)
# outputs True even if the response is already complete and no more pages are expected
Versions
oci==2.131.0
The text was updated successfully, but these errors were encountered:
farisdurrani
changed the title
Pagination does not work for identity_domains_client.list_groups if attributes are added
Pagination does not work for identity_domains_client.list_groups if attributes are added
Oct 9, 2024
The below code attempts to list all groups in an identity domain. However, adding either
attribute_sets
orattributes
will cause the response to indicatehas_next_page == True
andnext_page
to have a value even if the results are already complete.Versions
The text was updated successfully, but these errors were encountered: