# HG changeset patch # User ecology # Date 1712768089 0 # Node ID d266345e510d3b00733fee6804cfab25a44f8d3b # Parent 0ed34e3202b984f1e6a95ddcb302c128c19ef736 planemo upload for repository https://github.com/galaxyecology/tools-ecology/tree/master/tools/OtbBandMath commit bdeb782599ab8ec92de67e81ad092defe9edd56e diff -r 0ed34e3202b9 -r d266345e510d OTB_BandMath.R --- a/OTB_BandMath.R Tue Mar 12 12:39:59 2024 +0000 +++ b/OTB_BandMath.R Wed Apr 10 16:54:49 2024 +0000 @@ -124,16 +124,13 @@ } } else if (response2$status=="failed") { status <- "failed" - } - #else { - # attempt <- attempt +1 - # if (attempt == 200) { - # status <- "failed" - # } - #} + message("An error occurred. For further details, check OGC Job status through https://ospd.geolabs.fr:8300/ogc-api/jobs/", response2$jobID) + q(status = 1) + } } else { status <- "failed" - print(paste("HTTP", status_code2, "Error:", resp2$status_message)) + print(paste("HTTP", status_code2, "Error:", resp2$status_message, "An error occurred. For further details, check OGC Job status through https://ospd.geolabs.fr:8300/ogc-api/jobs/", response2$jobID)) + q(status = 1) } Sys.sleep(3) } @@ -147,4 +144,8 @@ } else { print(paste("HTTP", status_code1, "Error:", resp1$status_message)) } +}, error = function(e) { + message("An error occurred:", e) + # Exit with code 1 + q(status = 1) }) \ No newline at end of file