def __get_from_imports(import_tuples):
    """ Returns import names and fromlist
    import_tuples are specified as
    (name, fromlist, ispackage)
    """
    from_imports = [(tup[0], tup[1]) for tup in import_tuples
                    if tup[1] is not None and len(tup[1]) > 0]
    return from_imports