-
Notifications
You must be signed in to change notification settings - Fork 3
Fix Pacbio read calculation #4748
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
| ): | ||
| pass | ||
| def recalculate_sample_reads_pacbio(self, sample_id: str) -> None: | ||
| reads = sum( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess it is not obvious that it is an int
| reads = sum( | |
| reads: int = sum( |
| reads: int = 10000 | ||
|
|
||
| # WHEN updating the reads for the sample | ||
| store.update_sample_reads(internal_id=pacbio_barcoded_sample_internal_id, reads=reads) | ||
| store.update_sample_reads_pacbio(internal_id=pacbio_barcoded_sample_internal_id, reads=reads) | ||
|
|
||
| # THEN the reads for the sample is updated | ||
| sample: Sample = store.get_sample_by_internal_id(pacbio_barcoded_sample_internal_id) | ||
| assert sample.reads == reads |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest this test(test_update_sample_reads_pacbio) be removed. Seems to me that the new test (test_update_sample_reads_pacbio_not_incremented) covers all the functionality
diitaz93
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great ⭐
|




Description
Closes #4675. Currently, Pacbio samples gets their reads incremented rather than updated. When the same SMRT cell is post processed multiple times (in e.g. deviations), this causes the samples to display the wrong number of reads.
Added
Changed
Fixed
How to prepare for test
uspaxaHow to test
Expected test outcome
Review
Thanks for filling in who performed the code review and the test!
This version is a
Implementation Plan