scripts/release/rethreshold_family.py
def is_valid_family(dest_dir, rfam_acc):
    """
    Checks if the job ran successfully by checking if .err file is empty and
    that Success keyword exists in .out file. As an additional sanity check, we
    look for the rfsearch.log file as an indication that rfsearch actually ran.

    return: True if the family is valid, False otherwise
    """

    family_dir = os.path.join(dest_dir, rfam_acc)

    # If log file does not exist rfsearch did not run for some reason
    if not os.path.exists(os.path.join(family_dir, "rfsearch.log")):
        return False

    # check if lsf .err file is empty
    if not os.path.getsize(os.path.join(family_dir, "auto_rfsearch.err")) == 0:
        return check_rfsearch_log_success(family_dir)

    # check if success in .out file
    lsf_out_file = os.path.join(family_dir, "auto_rfsearch.out")

    process = Popen(['grep', 'Success', lsf_out_file], stdin=PIPE, stdout=PIPE, stderr=PIPE)
    output, err = process.communicate()

    if output.find("Successfully completed.") == -1:
        return False

    return True

    Checks if the job ran successfully by checking if .err file is empty and
    that Success keyword exists in .out file. As an additional sanity check, we
    look for the rfsearch.log file as an indication that rfsearch actually ran.

    return: True if the family is valid, False otherwise
    
Checks if the job ran successfully by checking if .err file is empty and
that Success keyword exists in .out file. As an additional sanity check, we
look for the rfsearch.log file as an indication that rfsearch actually ran.

True if the family is valid, False otherwise
Checks if the job ran successfully by checking if . err file is empty and that Success keyword exists in . out file . As an additional sanity check we look for the rfsearch . log file as an indication that rfsearch actually ran . True if the family is valid False otherwise
def is_valid_family(dest_dir, rfam_acc):
    family_dir = os.path.join(dest_dir, rfam_acc)
    if not os.path.exists(os.path.join(family_dir, "rfsearch.log")):
        return False
    if not os.path.getsize(os.path.join(family_dir, "auto_rfsearch.err")) == 0:
        return check_rfsearch_log_success(family_dir)
    lsf_out_file = os.path.join(family_dir, "auto_rfsearch.out")
    process = Popen(['grep', 'Success', lsf_out_file], stdin=PIPE, stdout=PIPE, stderr=PIPE)
    output, err = process.communicate()
    if output.find("Successfully completed.") == -1:
        return False
    return True
def is_valid_family ( dest_dir , rfam_acc ) : family_dir = os . path . join ( dest_dir , rfam_acc ) if not os . path . exists ( os . path . join ( family_dir , "rfsearch.log" ) ) : return False if not os . path . getsize ( os . path . join ( family_dir , "auto_rfsearch.err" ) ) == 0 : return check_rfsearch_log_success ( family_dir ) lsf_out_file = os . path . join ( family_dir , "auto_rfsearch.out" ) process = Popen ( [ 'grep' , 'Success' , lsf_out_file ] , stdin = PIPE , stdout = PIPE , stderr = PIPE ) output , err = process . communicate ( ) if output . find ( "Successfully completed." ) == - 1 : return False return True
Checks if the job ran successfully by checking if .err file is empty and
that Success keyword exists in .out file.
Checks if the job ran successfully by checking if . err file is empty and that Success keyword exists in . out file .
"""
    Checks if the job ran successfully by checking if .err file is empty and
    that Success keyword exists in .out file. As an additional sanity check, we
    look for the rfsearch.log file as an indication that rfsearch actually ran.

    return: True if the family is valid, False otherwise
    """ # If log file does not exist rfsearch did not run for some reason # check if lsf .err file is empty # check if success in .out file
dest_dir
rfam_acc