TypeError fix for unexpected NoneType in list
FIX: TypeError: unsupported operand type(s) for +: 'int' and 'NoneType' Caused when the "finished" list is summed with the function "sum".
This commit is contained in:
parent
22210ca352
commit
10a4ccba0a
|
@ -1656,6 +1656,7 @@ class Speedtest(object):
|
|||
while _is_alive(thread):
|
||||
thread.join(timeout=0.001)
|
||||
in_flight['threads'] -= 1
|
||||
if type(thread.result) in (int, float):
|
||||
finished.append(thread.result)
|
||||
callback(thread.i, request_count, end=True)
|
||||
|
||||
|
|
Loading…
Reference in New Issue