Skip to content

check:portal compares only the same release of a study - #503

Merged
alisman merged 1 commit into
masterfrom
portal-parity-import-dates
Nov 25, 2026
Merged

alisman merged 1 commit into
masterfrom
portal-parity-import-dates

Conversation

@alisman

@alisman alisman commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

Summary

scripts/check-portal-parity.ts (the gate's "counts against cBioPortal") now compares only the same release of each study.

Why. cbioportal.org re-imported msk_impact_2017 on 2026-11-24 07:17. The warehouse's copy is from 2026-07-28. Since then, gate-warehouse fails on master and on every pull request with 13 mutation-count mismatches (KRAS 1661 vs 1654, NF1 629 vs 628, …). Our numbers haven't changed; master's Nov 23 report has cBioPortal at 1661 too. A re-run of master's gate-warehouse (run 45228248171, 328f8b1) failed with the same 13.

What changes

  • At the start, the check reads every study's import date from cbioportal.org (/api/studies) and from the warehouse (cancer_study.import_date). A study whose dates differ, to the second, is stale. Today only msk_impact_2017 is stale; the other 19 studies the check uses match exactly.
  • A disagreement on a comparison that names a stale study prints STALE instead of FAIL. It is kept out of checks and doesn't fail the run. Agreements on a stale study still count.
  • At the end, each stale study gets one line: both import dates and how many disagreements were set aside.
  • With RECORD=1, the report adds stale (study, both dates, disagreements) and staleChecks (the set-aside rows). /verification doesn't show them yet.
  • A study missing on either side isn't stale; its comparisons fail as before.

Every study whose two copies match is still compared exactly, with no tolerance.

Caveat. While msk_impact_2017 is stale, a planted bug that only the msk_impact_2017 comparisons catch would survive the planted-bugs check. The real fix is still refreshing the warehouse's msk_impact_2017. This keeps the gate usable until then and says plainly what's stale.

Verification

  • tsc --noEmit and eslint are clean.
  • The import-date comparison was checked by hand against the warehouse and cbioportal.org: 19 of 20 studies match to the second, and msk_impact_2017 differs (07-28 vs 11-24).
  • I didn't run the full check locally (it's the heavy warehouse run). This PR's gate-warehouse is the test: it should pass, with msk_impact_2017's 13 disagreements listed as STALE.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Q3ezTaCo6wHFVsML6Qd4ht


Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

A study whose import date on cbioportal.org differs from the warehouse's is stale: cBioPortal
re-imported it after our copy was loaded. Its disagreements are listed as STALE, apart from the
comparisons, and don't fail the run; its agreements still count. Every other study is still
compared exactly.

cbioportal.org re-imported msk_impact_2017 on 2026-11-24; the warehouse's copy is from
2026-07-28, so gate-warehouse failed on master and on every pull request.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Q3ezTaCo6wHFVsML6Qd4ht
@vercel

vercel Bot commented Nov 24, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
cbiolab-genie Ready Ready Preview Nov 24, 2026 11:11pm UTC
cbiolab-new Ready Ready Preview Nov 24, 2026 11:11pm UTC
cohort-lab Ready Ready Preview Nov 24, 2026 11:11pm UTC

Request Review

@alisman
alisman added this pull request to the merge queue Nov 25, 2026
Merged via the queue into master with commit 9c13605 Nov 25, 2026
13 checks passed
@alisman
alisman deleted the portal-parity-import-dates branch November 25, 2026 01:40

This branch was successfully deployed

1 active deployment
Preview – cohort-lab — 66a50d0f Deployed Nov 24, 2026 by vercel[bot]
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