Skip to content

fix: verify the dataset revision returned by HTTP row pages - #82

Open
Afloat16 wants to merge 1 commit into
billion-token-one-task:masterfrom
Afloat16:fix/http-dataset-revision-check-20261202-r2
Open

Afloat16 wants to merge 1 commit into
billion-token-one-task:masterfrom
Afloat16:fix/http-dataset-revision-check-20261202-r2

Conversation

@Afloat16

@Afloat16 Afloat16 commented Dec 2, 2026

Copy link
Copy Markdown

Problem

The hosted runner's HTTP fallback reads Dataset Viewer rows without checking their revision, but its manifest records the requested/resolved dataset commit. A stale viewer cache or revision change between pages can therefore produce data that does not match the recorded experimental provenance. Non-default branch/tag requests are silently replaced by the viewer's default dataset.

Changes

Check the service's X-Revision on every page against the pinned commit. For the default main request, bind the first observed commit, require all subsequent pages to match, and record that commit in the manifest. Refuse missing/malformed revisions and non-default symbolic refs the viewer cannot resolve, with an instruction to use the datasets loader.

Primary implementation references:

Validation

  • 6 failed, 1 passed on base.
  • Controlled HTTP responses cover mismatched/missing/malformed revision headers, revision drift between pages, main binding, unsupported symbolic refs, and a matching pin.
  • python -m pytest -q tests/test_http_dataset_revision.py tests/test_runner_contract_and_failure_policy.py tests/test_served_model_provenance.py: 47 passed, 26 subtests passed.

For main, the recorded revision is the viewer's observed cached commit; this does not claim the cache is the latest Hub commit.

@cla-assistant

cla-assistant Bot commented Dec 2, 2026

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

1 similar comment
@cla-assistant

cla-assistant Bot commented Dec 2, 2026

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant