Skip to content

Commit

Permalink
Merge pull request #4573 from jedwards4b/env_batch_queue_fix
Browse files Browse the repository at this point in the history
fix an issue with queue-specific directives
  • Loading branch information
jedwards4b authored Jan 29, 2024
2 parents a488510 + 15ddca2 commit b5d9ed9
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion config/cesm/machines/config_machines.xml
Original file line number Diff line number Diff line change
Expand Up @@ -996,7 +996,7 @@ This allows using a different mpirun command to launch unit tests
<DESC>NCAR AMD EPYC </DESC>
<NODENAME_REGEX>de.*.hpc.ucar.edu</NODENAME_REGEX>
<OS>CNL</OS>
<COMPILERS>intel</COMPILERS>
<COMPILERS>intel,gnu</COMPILERS>
<!-- <COMPILERS>intel,gnu,cray,nvhpc,intel-oneapi,intel-classic</COMPILERS> -->
<MPILIBS>mpich</MPILIBS>
<CIME_OUTPUT_ROOT>$ENV{SCRATCH}</CIME_OUTPUT_ROOT>
Expand Down
2 changes: 1 addition & 1 deletion scripts/fortran_unit_testing/run_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ def parse_command_line(args):

args = CIME.utils.parse_args_and_handle_standard_logging_options(args, parser)
output = Printer(color=args.color)

if args.xml_test_list is None and args.test_spec_dir is None:
output.print_error(
"You must specify either --test-spec-dir or --xml-test-list."
Expand Down
1 change: 1 addition & 0 deletions scripts/lib/CIME/SystemTests/system_tests_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,7 @@ def _compare_baseline(self):
"""
compare the current test output to a baseline result
"""
memlist = None
with self._test_status:
# compare baseline
success, comments = compare_baseline(self._case)
Expand Down
3 changes: 2 additions & 1 deletion scripts/lib/CIME/XML/env_batch.py
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,8 @@ def get_batch_directives(self, case, job, overrides=None, output_format='default
directive_prefix = None

roots = self.get_children("batch_system")
queue = self.get_value("JOB_QUEUE", subgroup=job)
# This must go through the case object
queue = case.get_value("JOB_QUEUE", subgroup=job)
if self._batchtype != "none" and not queue in self._get_all_queue_names():
unknown_queue = True
qnode = self.get_default_queue()
Expand Down
6 changes: 3 additions & 3 deletions scripts/lib/CIME/XML/machines.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ def is_valid_compiler(self,compiler):
"""
Check the compiler is valid for the current machine
>>> machobj = Machines(machine="cori-haswell")
>>> machobj = Machines(machine="derecho")
>>> machobj.get_default_compiler()
'intel'
>>> machobj.is_valid_compiler("gnu")
Expand All @@ -266,7 +266,7 @@ def is_valid_MPIlib(self, mpilib, attributes=None):
"""
Check the MPILIB is valid for the current machine
>>> machobj = Machines(machine="cori-haswell")
>>> machobj = Machines(machine="derecho")
>>> machobj.is_valid_MPIlib("mpi-serial")
True
>>> machobj.is_valid_MPIlib("fake-mpi")
Expand All @@ -279,7 +279,7 @@ def has_batch_system(self):
"""
Return if this machine has a batch system
>>> machobj = Machines(machine="cori-haswell")
>>> machobj = Machines(machine="derecho")
>>> machobj.has_batch_system()
True
>>> machobj.set_machine("melvin")
Expand Down
2 changes: 1 addition & 1 deletion scripts/lib/CIME/code_checker.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
###############################################################################
def _run_pylint(on_file, interactive):
###############################################################################
pylint = find_executable("pylint")
pylint = find_executable("pylint")

cmd_options = " --disable=I,C,R,logging-not-lazy,wildcard-import,unused-wildcard-import"
cmd_options += ",fixme,broad-except,bare-except,eval-used,exec-used,global-statement"
Expand Down
2 changes: 1 addition & 1 deletion scripts/tests/scripts_regression_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -2764,7 +2764,7 @@ def check_for_pylint():
from distutils.spawn import find_executable
pylint = find_executable("pylint")
if pylint is not None:
output = run_cmd_no_fail("pylint --version")
output = run_cmd_no_fail(pylint+" --version")
pylintver = re.search(r"pylint\s+(\d+)[.](\d+)[.](\d+)", output)
major = int(pylintver.group(1))
minor = int(pylintver.group(2))
Expand Down

0 comments on commit b5d9ed9

Please sign in to comment.