jfinkels / flask-restless

NO LONGER MAINTAINED - A Flask extension for creating simple ReSTful JSON APIs from SQLAlchemy models.
https://flask-restless.readthedocs.io
GNU Affero General Public License v3.0
1.02k stars 301 forks source link

[1.0.0b1] Disabling pagination behavior doesn't match documentation #632

Open jatowler opened 7 years ago

jatowler commented 7 years ago

In 0.17.0, setting max_results_per_page to 0 or less disabled pagination. The documentation for 1.0.0b1 says this behavior is retained for the new parameter max_page_size, but that does not appear to be the case.

The effect is only achieved by setting page_size=0 and max_page_size=0.

This behavior can be confirmed by looking at _paginated, specifically the conditionals on L1420, L1422, L1428. Compare with _compute_results_per_page from 0.17.0, which has the behavior described in the documentation.

What is the intended behavior?