Skip to content
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

Improve error-handling in modules/samplesheet.nf when the filename doesn't match a regex #27

Open
ahmed-said-jax opened this issue Sep 3, 2024 · 0 comments
Assignees
Labels
bug Something isn't working enhancement New feature or request

Comments

@ahmed-said-jax
Copy link
Collaborator

Line 38 in modules/samplesheet.nf assumes that the filename matches the provided regex, and then tries to index into the string. BUT the string doesn't exist, so you just get an InvocationTargetException that points at an IndexOutOfBoundsException, which basically tells you nothing. We can actually just CHECK if the regex matched, and if not, we can provide a helpful error, saying "change the filename" or something like that.

Maybe this behavior can be fundamentally improved - do we need to match a regex? Can we just assume that every file in the directory is actually a fastq, regardless of its name? I think the name of the file is somehow important to cellranger, so that might not be an option.

@ahmed-said-jax ahmed-said-jax added bug Something isn't working enhancement New feature or request labels Sep 3, 2024
@ahmed-said-jax ahmed-said-jax self-assigned this Sep 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant