From 282534525318815a7ca7cfc8dce21bd0f31dfde5 Mon Sep 17 00:00:00 2001 From: Gordon Murray Date: Thu, 11 Jun 2026 22:50:14 +0100 Subject: [PATCH] feat: raise row page-size cap from 200 to 1000 A developer asked for larger pages when reviewing data integrity across a table. The cap lived in two places: MAX_LIMIT in the backend (applied to /rows and /vector/preview) and the page-size dropdown in the frontend. Raise MAX_LIMIT to 1000 and add 500 and 1000 options to the dropdown. The default stays at 50. Vector cells keep their existing sparkline truncation, so the per-cell payload is unchanged. --- CHANGELOG.md | 3 +++ backend/app.py | 2 +- backend/tests/test_api.py | 3 ++- web/vanilla/index.html | 2 ++ 4 files changed, 8 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 227b6c9..10f62e8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Changed +- Maximum rows per page raised from 200 to 1000. The page-size dropdown gains 500 and 1000 options; the default stays at 50 (#58). + ### Docs - README screenshot replaced with one showing vector columns: CLIP badges, per-row sparklines, and the highlighted vector field in the schema panel. The old screenshot only showed scalar columns. diff --git a/backend/app.py b/backend/app.py index 288c50f..03e354a 100644 --- a/backend/app.py +++ b/backend/app.py @@ -51,7 +51,7 @@ async def startup_event(): ) DATA_PATH = Path(os.getenv("DATA_PATH", "/data")) -MAX_LIMIT = 200 +MAX_LIMIT = 1000 def validate_dataset_name(name: str) -> bool: return ( diff --git a/backend/tests/test_api.py b/backend/tests/test_api.py index bd5db28..1e253a9 100644 --- a/backend/tests/test_api.py +++ b/backend/tests/test_api.py @@ -128,7 +128,8 @@ def test_rows_offset_past_end(client): def test_rows_limit_bounds(client): assert client.get("/datasets/sample/rows", params={"limit": 0}).status_code == 422 - assert client.get("/datasets/sample/rows", params={"limit": 201}).status_code == 422 + assert client.get("/datasets/sample/rows", params={"limit": 1000}).status_code == 200 + assert client.get("/datasets/sample/rows", params={"limit": 1001}).status_code == 422 assert client.get("/datasets/sample/rows", params={"offset": -1}).status_code == 422 diff --git a/web/vanilla/index.html b/web/vanilla/index.html index bdeae7f..85cd52d 100644 --- a/web/vanilla/index.html +++ b/web/vanilla/index.html @@ -61,6 +61,8 @@

Select a dataset

+ +