Merge pull request #45958 from garethgreenaway/backport-fixing_mactests_queue_full

Backporting #45935 to 2017.7
This commit is contained in:
Nicole Thomas 2018-02-12 11:25:07 -05:00 committed by GitHub
commit bf03abd07c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -17,6 +17,7 @@ import logging.handlers
# Import salt libs
from salt.log.mixins import NewStyleClassMixIn, ExcInfoOnLogLevelFormatMixIn
from salt.ext.six.moves import queue
log = logging.getLogger(__name__)
@ -176,7 +177,7 @@ if sys.version_info < (3, 2):
'''
try:
self.queue.put_nowait(record)
except self.queue.Full:
except queue.Full:
sys.stderr.write('[WARNING ] Message queue is full, '
'unable to write "{0}" to log', record
)