Skip to content

Commit

Permalink
Add fcst dependency to ocnanalprep (#2728)
Browse files Browse the repository at this point in the history
Add previous cycle's `fcst` as a dependency to `ocnanalprep`

This ensures that the availability of restart files to the latter. This addresses a
seldomly-encountered race condition where `ocnanalprep` fails due to the
lack of the files.
  • Loading branch information
AndrewEichmann-NOAA authored Jul 9, 2024
1 parent 58fca16 commit 3ca7477
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion workflow/rocoto/gfs_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -659,7 +659,9 @@ def ocnanalprep(self):
deps = []
dep_dict = {'type': 'task', 'name': f'{self.cdump}prepoceanobs'}
deps.append(rocoto.add_dependency(dep_dict))
dependencies = rocoto.create_dependency(dep=deps)
dep_dict = {'type': 'task', 'name': 'gdasfcst', 'offset': f"-{timedelta_to_HMS(self._base['cycle_interval'])}"}
deps.append(rocoto.add_dependency(dep_dict))
dependencies = rocoto.create_dependency(dep_condition='and', dep=deps)

resources = self.get_resource('ocnanalprep')
task_name = f'{self.cdump}ocnanalprep'
Expand Down

0 comments on commit 3ca7477

Please sign in to comment.