mirror of
https://github.com/frappe/gunicorn.git
synced 2026-01-14 11:09:11 +08:00
Remove unused import and pass True instead of 1
The logging module checks exc_info as
if exc_info:
# ...
so passing True would be more readable.
This commit is contained in:
parent
7db09f1495
commit
51f49f4887
@ -11,7 +11,6 @@ import select
|
||||
import signal
|
||||
import sys
|
||||
import time
|
||||
import traceback
|
||||
|
||||
from gunicorn.errors import HaltServer, AppImportError
|
||||
from gunicorn.pidfile import Pidfile
|
||||
@ -208,7 +207,7 @@ class Arbiter(object):
|
||||
raise
|
||||
except Exception:
|
||||
self.log.info("Unhandled exception in main loop",
|
||||
exc_info=1)
|
||||
exc_info=True)
|
||||
self.stop(False)
|
||||
if self.pidfile is not None:
|
||||
self.pidfile.unlink()
|
||||
@ -519,7 +518,7 @@ class Arbiter(object):
|
||||
raise
|
||||
except AppImportError as e:
|
||||
self.log.debug("Exception while loading the application",
|
||||
exc_info=1)
|
||||
exc_info=True)
|
||||
print("%s" % e, file=sys.stderr)
|
||||
sys.stderr.flush()
|
||||
sys.exit(self.APP_LOAD_ERROR)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user