Skip to content

Commit b57a543

Browse files
Don't assume all jobs share the same keys in their limits
1 parent a61bad9 commit b57a543

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

redun/scheduler.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1313,7 +1313,7 @@ def _add_job_pending_limits(self, job: Job, eval_args: Tuple[Tuple, dict]) -> No
13131313

13141314
def _add_limits(self, limits1, limits2):
13151315
return {
1316-
limit_name: limits1[limit_name] + limits2[limit_name]
1316+
limit_name: limits1.get(limit_name, 0) + limits2.get(limit_name, 0)
13171317
for limit_name in set(limits1) | set(limits2)
13181318
}
13191319

0 commit comments

Comments
 (0)