We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 49d7149 commit c8ab6eeCopy full SHA for c8ab6ee
1 file changed
Lib/logging/__init__.py
@@ -1507,12 +1507,15 @@ def shutdown(handlerList=_handlerList):
1507
#errors might occur, for example, if files are locked
1508
#we just ignore them if raiseExceptions is not set
1509
try:
1510
+ h.acquire()
1511
h.flush()
1512
h.close()
1513
except:
1514
if raiseExceptions:
1515
raise
1516
#else, swallow
1517
+ finally:
1518
+ h.release()
1519
1520
#Let's try and shutdown automatically on application exit...
1521
0 commit comments