From d4cbf392af7bfcccedd3828f2ed97198f0edaea6 Mon Sep 17 00:00:00 2001 From: David Huber Date: Wed, 8 Jan 2025 16:14:13 +0000 Subject: [PATCH 1/3] Remove default C48_ATM case --- workflow/generate_workflows.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/workflow/generate_workflows.sh b/workflow/generate_workflows.sh index a5615a8b0d..cc6cbad4b9 100755 --- a/workflow/generate_workflows.sh +++ b/workflow/generate_workflows.sh @@ -43,7 +43,6 @@ function _usage() { Run all valid SFS cases in the specified YAML directory. NOTES: - - Only one of -G -E or -S may be specified - Valid cases are determined by the experiment:system key as well as the skip_ci_on_hosts list in each YAML. @@ -86,7 +85,7 @@ _specified_home=false _build=false _build_flags="" _update_submods=false -declare -a _yaml_list=("C48_ATM") +declare -a _yaml_list=("") _specified_yaml_list=false _yaml_dir="" # Will be set based off of HOMEgfs if not specified explicitly _specified_yaml_dir=false From ed7ad210f2d3be3394fa7d5805e12dc0d0b2f9a5 Mon Sep 17 00:00:00 2001 From: David Huber Date: Fri, 10 Jan 2025 14:09:02 +0000 Subject: [PATCH 2/3] Prevent duplicate tests when running generate_workflows --- workflow/generate_workflows.sh | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/workflow/generate_workflows.sh b/workflow/generate_workflows.sh index cc6cbad4b9..7c98cf05c9 100755 --- a/workflow/generate_workflows.sh +++ b/workflow/generate_workflows.sh @@ -17,13 +17,13 @@ function _usage() { directory up from this script's residing directory. -b Run build_all.sh with default flags - (build the UFS, UPP, UFS_Utils, and GFS-utils only + (build the UFS, UPP, UFS_Utils, and GFS-utils only) -u Update submodules before building and/or generating experiments. -y "list of YAMLs to run" If this option is not specified, the default case (C48_ATM) will be - run. This option is overidden by -G or -E (see below). + run. This option is incompatible with -G, -E, or -S. Example: -y "C48_ATM C48_S2SW C96C48_hybatmDA" -Y /path/to/directory/with/YAMLs @@ -85,7 +85,7 @@ _specified_home=false _build=false _build_flags="" _update_submods=false -declare -a _yaml_list=("") +declare -a _yaml_list=("C48_ATM") _specified_yaml_list=false _yaml_dir="" # Will be set based off of HOMEgfs if not specified explicitly _specified_yaml_dir=false @@ -222,6 +222,22 @@ else done fi +# Empty the _yaml_list array if -G, -E, and/or -S were selected +if [[ "${_run_all_gfs}" == "true" || \ + "${_run_all_gefs}" == "true" || \ + "${_run_all_sfs}" == "true" ]]; then + + # Raise an error if the user specified a yaml list and any of -G -E -S + if [[ "${_specified_yaml_list}" == "true" ]]; then + echo "Ambiguous case selection." + echo "Please select which tests to run explicitly with -y (test list) or" + echo "by specifying -G (all GFS), -E (all GEFS), and/or -S (all SFS), but not both." + exit 3 + fi + + _yaml_list=() +fi + # If -S is specified, exit (for now). # TODO when SFS tests come online, enable this option. if [[ "${_run_all_sfs}" == "true" ]]; then From 4f127de481f72e067bae4d578654e048594fe69a Mon Sep 17 00:00:00 2001 From: David Huber Date: Fri, 10 Jan 2025 14:16:28 +0000 Subject: [PATCH 3/3] Clarify error message --- workflow/generate_workflows.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/workflow/generate_workflows.sh b/workflow/generate_workflows.sh index 7c98cf05c9..dbd360fda2 100755 --- a/workflow/generate_workflows.sh +++ b/workflow/generate_workflows.sh @@ -230,7 +230,7 @@ if [[ "${_run_all_gfs}" == "true" || \ # Raise an error if the user specified a yaml list and any of -G -E -S if [[ "${_specified_yaml_list}" == "true" ]]; then echo "Ambiguous case selection." - echo "Please select which tests to run explicitly with -y (test list) or" + echo "Please select which tests to run explicitly with -y \"list of tests\" or" echo "by specifying -G (all GFS), -E (all GEFS), and/or -S (all SFS), but not both." exit 3 fi