Skip to content

Add checks for uniqueness of sample ids #1902

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

Open
wants to merge 6 commits into
base: dev
Choose a base branch
from

Conversation

famosab
Copy link
Contributor

@famosab famosab commented May 26, 2025

PR checklist

Closes #1674

  • This comment contains a description of changes (with reason).
  • If you've fixed a bug or added code that should be tested, add tests!
  • If you've added a new tool - have you followed the pipeline conventions in the contribution docs
  • If necessary, also make a PR on the nf-core/sarek branch on the nf-core/test-datasets repository.
  • Make sure your code lints (nf-core pipelines lint).
  • Ensure the test suite passes (nextflow run . -profile test,docker --outdir <OUTDIR>).
  • Check for unexpected warnings in debug mode (nextflow run . -profile debug,test,docker --outdir <OUTDIR>).
  • Usage Documentation in docs/usage.md is updated.
  • Output Documentation in docs/output.md is updated.
  • CHANGELOG.md is updated.
  • README.md is updated (including new tool citations and authors/contributors).

Comment on lines +61 to +64
[meta.patient, meta.subMap('sample', 'status')]
}
.unique()
.groupTuple()
Copy link
Contributor

Choose a reason for hiding this comment

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

let's double check here that we are not collapsing out lane

@famosab famosab added this to the 3.6 milestone May 26, 2025
@@ -39,7 +59,7 @@ nextflow_pipeline {
assert workflow.failed
assertAll(
{ assert snapshot(
workflow.stderr.toString().replace("[", "").replace("]", "").split(",")[0]
workflow.stderr.toString().contains("Patient [test] has more than one sample [2] with normal status [0] and one sample with tumor status [1].")
Copy link
Member

Choose a reason for hiding this comment

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

why changing this test?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

for me this was inconsitent across the nextflow versions so that I always got a mismatch

Comment on lines -14 to -20
[
"\u001b0;31mThe following invalid input values have been detected:",
" ",
" \t-> Entry 2: Error for field 'sample' (test 2): \"test 2\" does not match regular expression ^\\S+$ (Sample ID must be provided",
" cannot contain spaces and must be a string value)",
" \u001b0m"
]
Copy link
Member

Choose a reason for hiding this comment

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

I liked that we were capturing the stderr 😢

Copy link
Contributor Author

Choose a reason for hiding this comment

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

for me this was inconsitent across the nextflow versions so that I always got a mismatch

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.

Pipeline does not stop immediately, when non-unique samples are provided in the samplesheet
3 participants