-
Notifications
You must be signed in to change notification settings - Fork 595
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
Order of 'includeConfig' and 'profiles' in nextflow.config seems to affect nested property overrides #4960
Comments
This will be fixed by #4744 |
Thanks @bentsherman ! |
I'm not 100% sure this is going to be by #4744. We advice to avoid the pattern you are using for some limitation of the underlying parsing library. See the red box at this link in the docs. A better way to handle your need is to use the
I get the following config
|
It is a suboptimal pattern, but it will be fixed by the new config parser |
The may new config parser solve this problem, however is still under development and surely it's not going delivered soon. The current best practice consists of using separate profiles as reported in the documentation |
Bug report
Expected behavior and actual behavior
Hi Nextflow team,
I expected that the order in which 'includeConfig' and 'profiles' are declared in nextflow.config would have no effect on property values.
However, I think I'm seeing that 'profiles' must be declared after any 'includeConfig' statements, in order for profile overrides to work correctly. In particular, this seems to affect what I'd describe as nested properties.
Steps to reproduce the problem
Given the following two files:
nextflow.config:
and memory.config:
and using the following command line invocation:
nextflow config -profile hpc
The nested properties 'process_nested.value' and 'labelExample' fail to be overridden by the hpc profile, while 'process_nonest' is correctly overridden.
(Of note, the problematic overrides work as expected once the 'includeConfig' declaration is moved above the 'profiles' declaration)
Program output
the unexpected output is as follows:
(No .nextflow.log is generated by nextflow config)
Environment
Additional context
The example provided is for the nextflow config command, but I'm also seeing similar behavior for nextflow run
The text was updated successfully, but these errors were encountered: