def still_a_dependency(dependency):
    """
    Defines the criteria for which a dependency is deemed complete (and therefore no longer a dependency).

     Args:
        dependency, Table.Row or dict. Processing row corresponding to the required input for the job in prow.
                                     This must contain keyword accessible values for 'STATUS', and 'LATEST_QID'.

    Returns:
        bool. False if the criteria indicate that the dependency is completed and no longer a blocking factor (ie no longer
              a genuine dependency). Returns True if the dependency is still a blocking factor such that the slurm
              scheduler needs to be aware of the pending job.

    """
    return dependency['LATEST_QID'] > 0 and dependency['STATUS'] != 'COMPLETED'