Restructured import os to be effective in monkey_patching

Change-Id: Ib12b1a8d515450a8c3ba39c7494ee9e5de80f24c
This commit is contained in:
Kushal Agrawal 2018-05-21 14:58:33 +05:30
parent 03114fb80c
commit 9389a33a52
1 changed files with 2 additions and 1 deletions

View File

@ -19,7 +19,6 @@
Glare (Glare Artifact Repository) API service.
"""
import os
import sys
import eventlet
@ -28,6 +27,8 @@ from oslo_utils import encodeutils
eventlet.patcher.monkey_patch(all=False, socket=True, time=True,
select=True, thread=True, os=True, MySQLdb=True)
import os
# If ../glare/__init__.py exists, add ../ to Python search path, so that
# it will override what happens to be installed in /usr/(local/)lib/python...
possible_topdir = os.path.normpath(os.path.join(os.path.abspath(sys.argv[0]),