Skip to content

Commit 1ce6019

Browse files
committed
Add comment
1 parent 03bac49 commit 1ce6019

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/uwtools/drivers/ungrib.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,8 +133,8 @@ def output(self) -> dict[str, list[Path]]:
133133
while current <= stop:
134134
fn = "%s:%s" % (self.PREFIX, current.strftime("%Y-%m-%d_%H"))
135135
paths.append(self.rundir / fn)
136-
if increment == 0:
137-
break
136+
if increment == 0: # the loop condition will never be false...
137+
break # ...so break to avoid infinite loop.
138138
current += timedelta(seconds=increment)
139139
return {"paths": paths}
140140

0 commit comments

Comments
 (0)