Skip to content

max parameter on list() methods doesn't work #7

@alfdelgado

Description

@alfdelgado

The max parameter does not actually limit the number of items retrieved.

The reason for this seems to be lines 79 through 90 in restsession.py

After calling requests.get() [line 77], the response is checked and yielded [lines 81 and 82]. But then the next page is requested and assigned to the response variable [lines 84 through 87], and the while loop [line 79] reprocesses the variable.

A simple solution would be to remove the loop altogether, leaving just lines 80 through 82; but I don't know if the paged behaviour is needed by other methods.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions