We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 47286d7 + d967ffa commit ecd9c5aCopy full SHA for ecd9c5a
readthedocs/builds/tasks.py
@@ -82,7 +82,7 @@ def route_for_task(self, task, args, kwargs, **__):
82
83
# Build time average is high
84
length_avg = queryset.filter(pk__in=last_builds).aggregate(Avg('length')).get('length__avg')
85
- if length_avg > self.TIME_AVERAGE:
+ if length_avg and length_avg > self.TIME_AVERAGE:
86
log.info(
87
'Routing task because project has high time average. queue=%s',
88
self.BUILD_LARGE_QUEUE,
0 commit comments