redid prog_func as log_progress