Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions infra/cargo-target-janitor/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,25 @@ numeric `~/git/fleet/target-<task-id>` ad-hoc targets.
violating the safety exclusions. A maximum of 20 exact target paths is
handled per run, so subsequent hourly runs continue eligible cleanup.

## Pagination contract (design #6622, closing inventory #6623)

A paged read is complete, bounded, or says so (design #6622, closing
inventory #6623):
1. The cursor is validated where read — its type first (where the
protocol's terminator is null, a present-but-non-string cursor is
malformed, never end-of-pages) and its progress second (the
cursor must advance under the protocol's rule).
2. The volume is bounded — every page loop carries a page, result,
or byte bound whose breach is an error naming the listing.
3. Truncation is never silent — a read that stops short either
paginates to completion (or counts via the source's own total),
fails closed, or marks the truncation explicitly in its output.

This tool's liveness reads carry the fail-closed form: the
claimed-task and open-PR-branch reads paginate to completion and
raise on a full page at the cap (`MAX_PR_PAGES`) rather than
presenting a page as the set (#6618).

## Run and schedule

From the laptop:
Expand Down
19 changes: 19 additions & 0 deletions infra/github-backup/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,25 @@ The seven rules, in operator language:
previously planned entries, marks them retained in the report,
and still exits non-zero.

## Pagination contract (design #6622, closing inventory #6623)

A paged read is complete, bounded, or says so (design #6622, closing
inventory #6623):
1. The cursor is validated where read — its type first (where the
protocol's terminator is null, a present-but-non-string cursor is
malformed, never end-of-pages) and its progress second (the
cursor must advance under the protocol's rule).
2. The volume is bounded — every page loop carries a page, result,
or byte bound whose breach is an error naming the listing.
3. Truncation is never silent — a read that stops short either
paginates to completion (or counts via the source's own total),
fails closed, or marks the truncation explicitly in its output.

This system's readers carry it as: the `queue_events` drain's
page/event bounds (bin/drain_queue.py, #6572) and
`inventory_owner`'s advancing-cursor validation with its
`MAX_INVENTORY_PAGES` hard bound (bin/ghb_common.py, #6532/#6840).

## Components

| Path | What |
Expand Down
19 changes: 19 additions & 0 deletions pkgs/cold-store-reaper/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,25 @@ Drive web UI for "the same" cold store) are **invisible to this app** and
must never be wired in by ID. If `state.json` is lost, `ensure-folders`
finds the existing tree again by name — it does not duplicate it.

## Pagination contract (design #6622, closing inventory #6623)

A paged read is complete, bounded, or says so (design #6622, closing
inventory #6623):
1. The cursor is validated where read — its type first (where the
protocol's terminator is null, a present-but-non-string cursor is
malformed, never end-of-pages) and its progress second (the
cursor must advance under the protocol's rule).
2. The volume is bounded — every page loop carries a page, result,
or byte bound whose breach is an error naming the listing.
3. Truncation is never silent — a read that stops short either
paginates to completion (or counts via the source's own total),
fails closed, or marks the truncation explicitly in its output.

This system's listings carry it as: `list_backups` and
`s3_list_objects` validate continuation-token progress (repeated
tokens are refused) under the shared `LIST_MAX_PAGES` /
`LIST_MAX_RESULTS` bounds (cold_store.py, #6602).

## Credentials

No real credential values live in this repo, ever. The operator keeps the
Expand Down
19 changes: 19 additions & 0 deletions pkgs/fleet/crates/fleet-dispatch-test/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,25 @@
//! fleet-dispatch-test — the dispatch-test domain of the fleet
//! multicall binary (design: developing-today/code#6580).
//!
//! ## Pagination contract (#6622)
//!
//! A paged read is complete, bounded, or says so (design #6622, closing
//! inventory #6623):
//! 1. The cursor is validated where read — its type first (where the
//! protocol's terminator is null, a present-but-non-string cursor is
//! malformed, never end-of-pages) and its progress second (the
//! cursor must advance under the protocol's rule).
//! 2. The volume is bounded — every page loop carries a page, result,
//! or byte bound whose breach is an error naming the listing.
//! 3. Truncation is never silent — a read that stops short either
//! paginates to completion (or counts via the source's own total),
//! fails closed, or marks the truncation explicitly in its output.
//!
//! The scan carries it as: `fetch_all_pages` reads each list to
//! completion under `MAX_PAGES`, past which the read errors instead
//! of presenting a page-bound count as exact; the queued-runs term
//! counts via the source's `total_count` (#6605).
//!
//! An explicit-dispatch CI test surface over GitHub Actions:
//!
//! fleet dispatch-test scan count active Actions jobs in each
Expand Down
19 changes: 19 additions & 0 deletions pkgs/id/crates/id-worlds/src/world_net.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,25 @@
//! `WorldClient` method against these rules is recorded on issue
//! #6670. A lax extraction found later is filed as a follow-up
//! issue, not patched silently and not defaulted around.
//!
//! ## The pagination contract (#6622)
//!
//! A paged read is complete, bounded, or says so (design #6622, closing
//! inventory #6623):
//! 1. The cursor is validated where read — its type first (where the
//! protocol's terminator is null, a present-but-non-string cursor is
//! malformed, never end-of-pages) and its progress second (the
//! cursor must advance under the protocol's rule).
//! 2. The volume is bounded — every page loop carries a page, result,
//! or byte bound whose breach is an error naming the listing.
//! 3. Truncation is never silent — a read that stops short either
//! paginates to completion (or counts via the source's own total),
//! fails closed, or marks the truncation explicitly in its output.
//!
//! This module's readers carry it as: `record_pages` (typed
//! string-or-null cursor, last-key match, empty-page refusal,
//! advance check, `RecordsBudget`) and `admin_event_history`
//! (typed cursor parse, missing-key refusal, `AdminHistoryBudget`).

use std::collections::HashMap;
use std::sync::{
Expand Down
Loading