Asana / python-asana

Official Python client library for the Asana API v1
MIT License
299 stars 103 forks source link

How to do pagination? #135

Closed w- closed 2 years ago

w- commented 2 years ago

docs here say pagination is strongly preferred https://developers.asana.com/docs/pagination

but looking at the code https://github.com/Asana/python-asana/blob/master/asana/client.py#L78

the request function completely discards next_page from results.

How are users expected to make use of pagination? What am i missing? my use case is retrieving tasks from a project

Thanks

w- commented 2 years ago

nm. i now see the extensive use of get_collection and how it automatically handles paging through results https://github.com/Asana/python-asana/blob/v0.10.3/asana/client.py#L175 https://github.com/Asana/python-asana/blob/v0.10.3/asana/page_iterator.py