Inheritance with multiple task params

Hi,

$ cat flow.cylc
[task parameters]
    world = Mercury, Venus, Earth
    num = 1..3
[scheduling]
    [[graph]]
        R1 = start => hello<world,num> => end

[runtime]
    [[start, end]]
    [[FAM<world,num>]]

    [[hello<world,num>]]
        inherit = FAM<world,num>
        script = echo 'Hello World!'
$ cylc validate .
ListValueError: (type=list) [runtime][hello<world,num>]inherit = FAM<world,num> - (names containing commas must be quoted(e.g. 'foo<m,n>'))

Changing the inherit = FAM<world,num> to inherit = FAM<world><num> passes validation (version 8.2.0 and 8.2.1).

Installing an old version: 8.1.0, and neither form works (looks like this behaviour is consistent with Cylc7).

$ conda activate cylc-8.1.0
$ cylc validate .
WorkflowConfigError: undefined parent for hello_Mercury_num1: FAM_Mercury<num>

I couldn’t see anything in the docs saying the first form is not allowed, but I may have missed it. My assumption is a bug or limitation, but it could be a design choice? This is what I could see in the docs:

image

Hi @TomC,

For multiple task parameters, only the original <m,n> syntax was formally supported before 8.2. The <m><n> syntax happened to work in some cases (essentially by accident!), but not with family names.

As of 8.2. we support both forms.

The instruction given in your validation error for inherit = FAM<world,num> (at both 8.1 and 8.2) is correct2: names containing commas must be quoted (e.g. ‘foo<m,n>’)

If you write inherit = "FAM<world,num>" it works. Quotes are needed here because the inherit config item is list-valued (with comma as separator).

The syntax and version compatibility (if not the quoting thing) are documented here: Task Parameters — Cylc 8.2.1 documentation

Ok. I was not interpreting that message how it is intended then. I interpreted it as you could have a family “A,B” and you have to quote that. If that isn’t possible, and it only applies to task parameters, then could that be spelt out in the error message to remove confusion? It would also be good to see an example of this in the docs.

Yes, I agree it’s not the most helpful error message in this circumstance! (It was designed for simpler, non-parameter, cases).

New issue posted for the fix: parameters: better warning for comma in inherit config item · Issue #5697 · cylc/cylc-flow · GitHub