From 527547a3eee788b52c28ae67163a97e4209b80a9 Mon Sep 17 00:00:00 2001 From: Nguyen Hung Phuong Date: Wed, 21 Feb 2018 17:56:41 +0700 Subject: [PATCH] Clean imports in code In some part in the code we import objects. In the Openstack style guidelines they recommend to import only modules. [1]: "Do not import objects, only modules". [1] https://docs.openstack.org/hacking/0.10.3/ Change-Id: Ib28240efb761a9426c57ac2551e0f19f07cdc2fb --- doc/source/redirect.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/source/redirect.py b/doc/source/redirect.py index 099159f..4400b98 100644 --- a/doc/source/redirect.py +++ b/doc/source/redirect.py @@ -10,8 +10,8 @@ from sphinx.util.console import bold def setup(app): - from sphinx.application import Sphinx - if not isinstance(app, Sphinx): + from sphinx import application + if not isinstance(app, application.Sphinx): return app.connect('build-finished', emit_redirects)