-
Notifications
You must be signed in to change notification settings - Fork 651
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
Conceptual error in process selector documentation #4416
Conversation
Hi, the documentation for this seems inaccurate to me. While the first part is true that the withName selector applies also to the original name of a module, not only the import name, in my usage experience it does also apply to the import name. For example if I have a process named FOO and I import it with import FOO as BAR, a withName:BAR selector will work, and also a withName:FOO selector will. The documentation suggests that only withName:FOO works, which I believe to be incorrect. Signed-off-by: Saul Pierotti <[email protected]>
✅ Deploy Preview for nextflow-docs-staging ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
If this is the case then we should probably change Nextflow to not apply process selectors for the base name to aliases. |
I actually find it useful to have it this way - I can have the same module and import it with two different aliases, and then have it run with different parameters/modes according to the alias. An example is https://nf-co.re/modules/stitch, which I import once for generating the input only with certain ext.args, and once for actually running the imputation with other ext.args. Or for example a very general module like the plink2 module. I may want to use it several times for doing different things and manage it via different ext.args. |
It seems to be the case, I can reproduce on my side, @bentsherman.
./main.nf
nextflow.config
./modules/foo/main.nf
Output:
|
Co-authored-by: Marcel Ribeiro-Dantas <[email protected]> Signed-off-by: Ben Sherman <[email protected]>
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.
Fair enough, I guess if you don't want the base config to be propagated to aliases then you can simply not use it and alias every process inclusion.
consider folding this PR into the module config #4510 |
Closing in favor of #4510 |
Hi, the documentation for this seems inaccurate to me. While the first part is true that the withName selector applies also to the original name of a module, not only the import name, in my usage experience it does also apply to the import name. For example if I have a process named FOO and I import it with import FOO as BAR, a withName:BAR selector will work, and also a withName:FOO selector will. The documentation suggests that only withName:FOO works, which I believe to be incorrect.