-
Notifications
You must be signed in to change notification settings - Fork 94
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
parameters: complete support for alternative syntax #5118
Comments
I think we can close this as invalid, possibly after adding a warning to the documentation and improved validation.
It should be [task parameters]
m = 1,2
n = a,b
[scheduling]
[[graph]]
R1 = "FOO<m,n>"
[runtime]
[[FOO<m,n>]]
[[foo<m,n>]]
inherit = "FOO<m,n>" |
And yet it works fine in In this particular example there is a semi-legit use case for separating the two:
|
I ran a quick scan for
All of these could have been implemented as Scanning for
I think the |
Yeah that pattern is equally natural, but we made a choice between several possible syntaxes back when originally implemented. Supporting multiple syntaxes for almost the same purpose would be a bit unusual. But we could certainly support that syntax as well, in principle, of course. It doesn't strike me as a high priority issue though. The ability to spread parameter task name components out a bit might be nice sometimes, but I doubt that its ever critical, esp. as we can at least control the order of the parameters. If it's easy to implement though, why not. It might well be easy given that it damn near works already! |
(It is interesting that a fair number of people are evidently using the "wrong" syntax though!) |
My scan's hanging but I wouldn't be surprised if the "wrong" usage outweighs the "correct" usage. Just feels more natural. |
Ok, we have a workaround, pushing this back. I think we need to address this as we currently support two syntaxes, but only one of them globally, which is highly confusing. TBH, I think Given that we've been supporting |
"currently support two syntaxes" is a bit of an overstatement! We have one supported and documented syntax, and another that some users have guessed at and which by some strange miracle happens to both work (in most but not all cases) and to not be actively disallowed. However, given that, I'm fine with formalizing the accidental support and extending it to make inheritance work. |
That's done by It doesn't work for this erm, alternative syntax, because the method (which is called once for each parent name) assumes all the parameters are contained within a single Probably not difficult to make it work. |
🛏️ |
Cylc allows us to inherit from parametrised families:
However, for some reason this only works when there is a single parameter involved, this example errors:
Reported with Cylc 7.
Pull requests welcome!
This is an Open Source project - please consider contributing a bug fix
yourself (please read
CONTRIBUTING.md
before starting any work though).The text was updated successfully, but these errors were encountered: