moved check_archive to utils