Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
calvinp0 committed Dec 17, 2023
1 parent d72403e commit b0f23c8
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions arc/job/trsh.py
Original file line number Diff line number Diff line change
Expand Up @@ -1133,18 +1133,18 @@ def trsh_job_queue(server: str,
Tuple[dict, bool]: A dictionary of the available queues and a boolean indicating if the function was successful.
"""

server_queues = servers[server].get('queue', list())
server_queues = servers[server].get('queue', dict())
cluster_soft = servers[server].get('cluster_soft','Undefined')
exclude_queues = servers[server].get('exclude_queues', list())

# Check if there are any available queues in server_queues that hasn't been tried yet
if len(server_queues) > 1:
# Make sure that the queue is not already in the attempted_queues list
server_queues = [
queue for queue in server_queues
if (attempted_queues is None or queue not in attempted_queues)
and convert_to_hours(server_queues[queue]) >= max_time
]
server_queues = {
queue: walltime for queue, walltime in server_queues.items()
if (attempted_queues is None or queue not in attempted_queues)
and convert_to_hours(walltime) >= max_time
}
if len(server_queues) == 0:
logger.error(f' Could not troubleshoot {job_name} on {server} as all available queues have been tried. Will attempt to query the server for additional queues.')

Check warning on line 1149 in arc/job/trsh.py

View check run for this annotation

Codecov / codecov/patch

arc/job/trsh.py#L1149

Added line #L1149 was not covered by tests
else:
Expand Down

0 comments on commit b0f23c8

Please sign in to comment.