Use jinja templates instead of @VARNAME@ in config files#3411
Conversation
…dd workflow/requirements.txt for easy creation of workflow virtual env. ignore the venv in HOMEgfs space. use detect_machine.sh in global-workflow instead of relying on the gfs-utils submodule
There was a problem hiding this comment.
ShellCheck found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.
Co-authored-by: David Huber <69919478+DavidHuber-NOAA@users.noreply.github.com>
…ate the method in task.py that validates the system keys for jinja. it should not be necessary, but is here to check
|
I am going to close this PR for now as I work through the unresolved issues. |
|
Checkout Failed on Hercules in Build# 8: Remote call on Hercules-EMC failed |
|
Build FAILED on Hercules in Build# 9 with error logs: Follow link here to view the contents of the above file(s): (link) |
@TerrenceMcGuinness-NOAA I am going to reset the label and hope that it kicks this back up |
|
Looking at the CI run on WCOSS2, it appears all tests have passed successfully under |
|
CI Passed on Hercules in Build# 10 |
Description
This PR:
@MACHINE@inconfig.basewith jinja template pattern{{ MACHINE }}setup_expt.pyscript is updated to remove custom code that was written to search and replace@VARNAME@with values from the experiment yamls. Jinja provides a much cleaner way to interface those two..j2inparm/config/<system>directory. e.g.config.baseis now namedconfig.base.j2inparm/config/gfs. It gets rendered asconfig.basein the experiment directory aftersetup_expt.pycompletes the execution.--accountargument insetup_expt.pyas opposed to replacingACCOUNTfromhosts/host.yaml.hosts/host.yamlinto sections forPaths,BQS properties,HPSS propertiesandFeaturesfor that host.In addition, this PR also:
create_experiment.py,setup_expt.pyandsetup_xml.py.host.pyto honorMACHINE_IDset by sourcingdetect_machine.sh.Resolves #3439
Type of change
Change characteristics
How has this been tested?
Experiment directories were created before and after this change and compared. Changes were in the expected places where template patterns were updated.
Checklist