Skip to main content

MAX_PAGES

Constant MAX_PAGES 

Source
pub const MAX_PAGES: usize = 100;
Expand description

The most pages either pagination loop follows before giving up.

A Link: rel="next" that points back at the page it arrived on — a proxy rewriting the header, or a bug at the other end — is an infinite loop inside the agent’s reconciliation loop, which is the one place in this product that must not be able to wedge. At per_page=100 this ceiling is ten thousand installations or repositories, past any real account by orders of magnitude, so it bounds the pathological case without truncating a legitimate one.