Skip to content

Add validation suite - #520

Merged
sgosline merged 3 commits into
mainfrom
build-validation-suite
Nov 3, 2026
Merged

sgosline merged 3 commits into
mainfrom
build-validation-suite

Conversation

@jjacobson95

@jjacobson95 jjacobson95 commented Oct 27, 2026 •

Copy link
Copy Markdown
Collaborator

Adds coderbuild/utils/validate_build.py, run by build_all.py --validate before the schema check. It catches problems the schema can't see, such as the duplicates in #512. Errors stop the build; warnings are listed for review.

Check Level
More than one result for a sample/drug/time/metric Error
Blank IDs, or IDs written as decimals (3524.0) Error
IDs not in the samples or drugs file Error
Sample IDs shared between datasets (cell lines excepted) Error
Samples with two model types, drugs with two structures, CIDs under two drug IDs Error
Conflicts in the stable ID mapping files Error
Responses copied across drug or sample IDs Warning
Conflicting sample names or cancer types Warning
Response metrics out of range or mostly blank Warning
Large changes or drops from the previous build, datasets no longer built (only with --previous-summary) Warning

Each build publishes validation_summary.json with its counts of samples, drugs and responses per dataset. Optionally, pass a previous build's summary with --previous-summary to compare against it; without it, the last check in the table is skipped. To run the checks on any folder: pytest tests/test_build_data.py --build-dir <folder>. Usage is in coderbuild/README.md.

Closes #515

@jjacobson95 jjacobson95 added this to the 2.4 new build milestone Oct 27, 2026
@jjacobson95 jjacobson95 added enhancement New feature or request 'build' update labels Oct 27, 2026
@jjacobson95 jjacobson95 self-assigned this Oct 27, 2026
@jjacobson95 jjacobson95 added enhancement New feature or request 'build' update labels Oct 27, 2026
@jjacobson95
jjacobson95 marked this pull request as ready for review October 27, 2026 20:37
@jjacobson95
jjacobson95 requested a review from sgosline October 27, 2026 20:37
@jjacobson95
jjacobson95 changed the base branch from main to mpnst-treated-samples-and-omics October 27, 2026 20:40
@jjacobson95
jjacobson95 changed the base branch from mpnst-treated-samples-and-omics to main October 27, 2026 20:40

@sgosline sgosline left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you add some inline comments to this script to help with future debugging?

@sgosline
sgosline merged commit f9a1a59 into main Nov 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

'build' update enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Test Suite before Schema Check in build_all.py

2 participants