Skip to main content

aip_sdk.TestPlanVersionPage

aip_sdk.TestPlanVersionPage(records: list[TestPlanSummary], total: int, next_before_version: int | None = None)

One page of a plan's version history: its rows, total, and the next-page cursor.

What list_test_plan_versions returns. Pages by cursor, not offset, so a publish landing mid-walk cannot hand back a version already read.

Pass next_before_version back as before_version until it comes back None, or let iter_test_plan_versions do it. It, not total, is the stop condition — unlike the same field on TestPlanPage, total is display only here.

Attributes

  • records list[TestPlanSummary]: The versions on this page, newest first.
  • total int: Versions of this plan stored in the workspace. Display only — it can grow mid-walk.
  • next_before_version int | None: Pass as before_version for the page below. None ends the history.

Examples

import aip_sdk as aip

page = aip.list_test_plan_versions("toxicity-baseline", workspace_id="ws_001", per_page=20)
for summary in page:
print(summary.version)
if page.next_before_version is not None:
print("more history below v", page.next_before_version)

aip_sdk.TestPlanVersionPage.next_before_version​

aip_sdk.TestPlanVersionPage.next_before_version: int | None = None

No docstring is defined in the source.

aip_sdk.TestPlanVersionPage.total​

aip_sdk.TestPlanVersionPage.total: int

No docstring is defined in the source.

Inherited members​

Inherited from libs/aip-sdk/src/aip_sdk/test_plan.py

aip_sdk.TestPlanVersionPage.records​

aip_sdk.TestPlanVersionPage.records: list[TestPlanSummary]

No docstring is defined in the source.