atlassian-api / atlassian-python-api

Atlassian Python REST API wrapper
https://atlassian-python-api.readthedocs.io
Apache License 2.0
1.34k stars 661 forks source link

Max of only 500 pages are returned #1380

Open amitjoy opened 5 months ago

amitjoy commented 5 months ago

while executing - atlassian.confluence.Confluence.get_all_pages_from_space with a limit set to 2000 still returns only 500 pages whereas the space has more than 500 pages. Is it a restriction? How can I retrieve all the pages setting the limit properly?

Spacetown commented 5 months ago

That's the limit of the server if you want to get more pages you need to define the start.

@gonchik I think it's really time to implement the paging in a generic way. The only problem is that the function than will return an generator instead of a list which can break custom scripts.

gkowalc commented 5 months ago

@Spacetown I agree, but this will be a major change that can break many things, so maybe this is something we can add to next major (4.x) version. For now, as a workaround maybe we should edit the docs to highlight the need of implementing pagination with few examples?

Spacetown commented 5 months ago

I tried yesterday to do the pagination in the rest client and configuring it in the module for the existing once.