From ffbfa512d36e6ef34937312bb175d4095f97ef5c Mon Sep 17 00:00:00 2001 From: David Bieber Date: Mon, 25 Nov 2019 09:38:19 -0800 Subject: [PATCH] Add disable=import-outside-toplevel pylint lines. PiperOrigin-RevId: 282375002 Change-Id: I83c9354df82baa8d31fb068cf06a02df35341c50 --- fire/inspectutils.py | 2 +- fire/interact.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/fire/inspectutils.py b/fire/inspectutils.py index aa130e05..6ccef5d2 100644 --- a/fire/inspectutils.py +++ b/fire/inspectutils.py @@ -191,7 +191,7 @@ def Info(component): A dict with information about the component. """ try: - from IPython.core import oinspect # pylint: disable=g-import-not-at-top + from IPython.core import oinspect # pylint: disable=import-outside-toplevel,g-import-not-at-top inspector = oinspect.Inspector() info = inspector.info(component) diff --git a/fire/interact.py b/fire/interact.py index 9f0a01e6..7df32841 100644 --- a/fire/interact.py +++ b/fire/interact.py @@ -89,11 +89,11 @@ def _EmbedIPython(variables, argv=None): Values are variable values. argv: The argv to use for starting ipython. Defaults to an empty list. """ - import IPython # pylint: disable=g-import-not-at-top + import IPython # pylint: disable=import-outside-toplevel,g-import-not-at-top argv = argv or [] IPython.start_ipython(argv=argv, user_ns=variables) def _EmbedCode(variables): - import code # pylint: disable=g-import-not-at-top + import code # pylint: disable=import-outside-toplevel,g-import-not-at-top code.InteractiveConsole(variables).interact()