From 89d41bd1fc6a9b812998b960da0b196240c98292 Mon Sep 17 00:00:00 2001 From: Jeffrey Armstrong Date: Mon, 6 Jan 2025 15:55:28 -0500 Subject: Result files being checked for existence now also checks for gz versions. --- captain/web.f90 | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/captain/web.f90 b/captain/web.f90 index eedb254..55d8ad2 100644 --- a/captain/web.f90 +++ b/captain/web.f90 @@ -747,6 +747,19 @@ contains end function generate_one_player_html + function file_or_compressed_file_exists(filename) result(file_exists) + implicit none + + character(len=*), intent(in)::filename + logical::file_exists + + inquire(file=filename, exist=file_exists) + if(.not. file_exists) then + inquire(file=trim(filename)//".gz", exist=file_exists) + end if + + end function file_or_compressed_file_exists + function generate_one_job_html(req) result(res) use captain_db use config @@ -810,7 +823,8 @@ contains status = get_status_utf8(tasks(i)%status) task_results_filename => get_task_result_static_filename(one_job%id, i, no_path=.true.) local_task_results_filename => get_task_result_static_filename(one_job%id, i, no_path=.false.) - inquire(file=local_task_results_filename, exist=file_exists) + + file_exists = file_or_compressed_file_exists(local_task_results_filename) write(task_text, '(I8)') i -- cgit v1.2.3