Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Ronnie Dutta <[email protected]>
  • Loading branch information
wxtim and MetRonnie authored Mar 4, 2024
1 parent 96db826 commit 0b41424
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
5 changes: 2 additions & 3 deletions cylc/flow/broadcast_mgr.py
Original file line number Diff line number Diff line change
Expand Up @@ -278,8 +278,7 @@ def put_broadcast(
with self.lock:
for setting in settings:
fail_cycle_points = setting.get(
'simulation', {'fail cycle points': None}).get(
'fail cycle points', None)
'simulation', {}).get('fail cycle points', None)
if fail_cycle_points:
from cylc.flow.simulation import parse_fail_cycle_points
try:
Expand Down Expand Up @@ -394,7 +393,7 @@ def _point_string_in_prunes(prunes, point_string):

@staticmethod
def _fail_points_in_prunes(prunes, fail_points):
"""Is point_string pruned?"""
"""Is fail cycle points pruned?"""
return fail_points in [prune[0] for prune in prunes]

def _prune(self):
Expand Down
5 changes: 3 additions & 2 deletions tests/integration/test_simulation.py
Original file line number Diff line number Diff line change
Expand Up @@ -408,8 +408,9 @@ async def test_settings_broadcast(
['1066'], ['one'], [{
'simulation': {'fail cycle points': '1'}
}])
assert {'fail cycle points': []} == (
schd.broadcast_mgr.broadcasts['1066']['one']['simulation'])
assert schd.broadcast_mgr.broadcasts['1066']['one'][
'simulation'
] == {'fail cycle points': []}

# Submit again - result is different:
schd.task_job_mgr._simulation_submit_task_jobs(
Expand Down

0 comments on commit 0b41424

Please sign in to comment.