pylint/checkers/python3.py
def _is_conditional_import(node):
    """Checks if an import node is in the context of a conditional.
    """
    parent = node.parent
    return isinstance(
        parent, (astroid.TryExcept, astroid.ExceptHandler, astroid.If, astroid.IfExp)
    )
def _is_conditional_import(node):
    parent = node.parent
    return isinstance(
        parent, (astroid.TryExcept, astroid.ExceptHandler, astroid.If, astroid.IfExp)
    )
def _is_conditional_import ( node ) : parent = node . parent return isinstance ( parent , ( astroid . TryExcept , astroid . ExceptHandler , astroid . If , astroid . IfExp ) )
Checks if an import node is in the context of a conditional.
Checks if an import node is in the context of a conditional .