Browse Source

Merge "Trivial:remove unused import and add reasonable path in import"

changes/27/562727/6
Zuul 4 years ago committed by Gerrit Code Review
parent
commit
b8db93abc4
  1. 10
      heat/common/wsgi.py

10
heat/common/wsgi.py

@ -38,9 +38,8 @@ from oslo_log import log as logging
from oslo_serialization import jsonutils
from oslo_utils import encodeutils
from oslo_utils import importutils
from paste import deploy
import routes
import routes.middleware
from paste.deploy import loadwsgi
from routes import middleware
import six
import webob.dec
import webob.exc
@ -693,8 +692,7 @@ class Router(object):
mapper.connect(None, "/v1.0/{path_info:.*}", controller=BlogApp())
"""
self.map = mapper
self._router = routes.middleware.RoutesMiddleware(self._dispatch,
self.map)
self._router = middleware.RoutesMiddleware(self._dispatch, self.map)
@webob.dec.wsgify
def __call__(self, req):
@ -1102,6 +1100,6 @@ def paste_deploy_app(paste_config_file, app_name, conf):
"""
setup_paste_factories(conf)
try:
return deploy.loadapp("config:%s" % paste_config_file, name=app_name)
return loadwsgi.loadapp("config:%s" % paste_config_file, name=app_name)
finally:
teardown_paste_factories()

Loading…
Cancel
Save