Skip to content

Fix #132: honor max_protein_sequences_per_variant in run_isovar#140

Merged
iskandr merged 1 commit into
masterfrom
fix-132-max-protein-sequences-cap
Apr 16, 2026
Merged

Fix #132: honor max_protein_sequences_per_variant in run_isovar#140
iskandr merged 1 commit into
masterfrom
fix-132-max-protein-sequences-cap

Conversation

@iskandr

@iskandr iskandr commented Apr 16, 2026

Copy link
Copy Markdown
Contributor

Summary

  • sorted_protein_sequences_for_variant now applies the max_protein_sequences_per_variant cap, so both run_isovar and the generator code path respect it.
  • Removed the redundant slice in protein_sequences_from_read_evidence_generator.
  • 3 regression tests: unit cap, unit no-cap, integration through run_isovar — all fail without the fix.
  • Bumped version to 1.4.4.

Fixes #132

Test plan

  • New regression tests fail without fix, pass with fix
  • ./test.sh passes (152 tests)
  • ./lint.sh passes

…ces_for_variant

Apply the cap inside sorted_protein_sequences_for_variant so both run_isovar
and protein_sequences_from_read_evidence_generator respect it. Remove the
now-redundant slice in the generator path.

Before this change, ProteinSequenceCreator(max_protein_sequences_per_variant=N)
and the --max-protein-sequences-per-variant CLI flag were silently ignored
when used through run_isovar (the main `isovar` CLI), since that code path
called sorted_protein_sequences_for_variant directly.

Adds three regression tests: unit test for the cap, unit test for the None
(no-cap) case, and integration test through run_isovar. All fail on the
unfixed code.

Fixes #132
@coveralls

coveralls commented Apr 16, 2026

Copy link
Copy Markdown

Coverage Status

coverage: 92.969% (+0.05%) from 92.923% — fix-132-max-protein-sequences-cap into master

@iskandr iskandr merged commit 62caca0 into master Apr 16, 2026
4 of 6 checks passed
@iskandr iskandr deleted the fix-132-max-protein-sequences-cap branch April 16, 2026 01:16
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.

Bug: max_protein_sequences_per_variant is silently ignored by run_isovar()

2 participants