add exception handle for file repeat