ext: Replace Queue.Empty with queue.empty
Queue.Empty is not an exception in python3 (Queue has been renamed to queue) Change-Id: I82555d96608094fa47990f888fd11663379547bc Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com> Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/40135 Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu> Reviewed-by: Jason Lowe-Power <power.jg@gmail.com> Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
committed by
Gabe Black
parent
85c1fdac29
commit
39046a0260
@@ -44,7 +44,7 @@ import testlib.result as result
|
||||
import testlib.state as state
|
||||
import testlib.terminal as terminal
|
||||
|
||||
from queue import Queue
|
||||
from queue import Queue, Empty
|
||||
from testlib.configuration import constants
|
||||
|
||||
|
||||
@@ -383,7 +383,7 @@ class MultiprocessingHandlerWrapper(object):
|
||||
raise
|
||||
except EOFError:
|
||||
return
|
||||
except Queue.Empty:
|
||||
except Empty:
|
||||
continue
|
||||
|
||||
def _drain(self):
|
||||
@@ -395,7 +395,7 @@ class MultiprocessingHandlerWrapper(object):
|
||||
raise
|
||||
except EOFError:
|
||||
return
|
||||
except Queue.Empty:
|
||||
except Empty:
|
||||
return
|
||||
|
||||
def _handle(self, record):
|
||||
|
||||
Reference in New Issue
Block a user