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

parameter templates and job environment #539

Open
hjoliver opened this issue Sep 20, 2022 · 0 comments
Open

parameter templates and job environment #539

hjoliver opened this issue Sep 20, 2022 · 0 comments
Labels
content Addition or modification of documentation
Milestone

Comments

@hjoliver
Copy link
Member

We should document more clearly that use of `parameter templates' changes the formatting of the parameter for use in task names, but it does not change the value of the parameter.

For example, if parameter m is an integer templated as %(03)s then foo<m> for m=3 becomes foo003 but in the job environment $CYLC_TASK_PARAM_m is just 3, not 003.

If the job needs the formatted value too, options are:

[runtime]
  [[foo<m>]]
    [[[environment]]]
       M1 = $(printf "%03d" $CYLC_TASK_PARAM_m)  # "003"
       M2 = %(m)03d  # "003"
@hjoliver hjoliver added this to the 8.1.0 milestone Sep 20, 2022
@oliver-sanders oliver-sanders modified the milestones: 8.1.0, 8.2.0 Dec 7, 2022
@oliver-sanders oliver-sanders modified the milestones: 8.2.0, 8.2.x Jul 17, 2023
@oliver-sanders oliver-sanders added the content Addition or modification of documentation label Feb 1, 2024
@oliver-sanders oliver-sanders modified the milestones: 8.2.x, 8.3.x Jun 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content Addition or modification of documentation
Projects
None yet
Development

No branches or pull requests

2 participants