Skip to content

Commit

Permalink
Add error message for missing container image with Google Batch (#3747)
Browse files Browse the repository at this point in the history
Signed-off-by: Ben Sherman <bentshermann@gmail.com>
  • Loading branch information
bentsherman committed Mar 14, 2023
1 parent 1d06e9a commit 6419e68
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ import groovy.transform.CompileStatic
import groovy.transform.PackageScope
import groovy.util.logging.Slf4j
import nextflow.cloud.google.batch.client.BatchClient
import nextflow.exception.ProcessUnrecoverableException
import nextflow.executor.BashWrapperBuilder
import nextflow.fusion.FusionAwareTask
import nextflow.fusion.FusionScriptLauncher
Expand Down Expand Up @@ -158,6 +159,9 @@ class GoogleBatchTaskHandler extends TaskHandler implements FusionAwareTask {
computeResource.setBootDiskMib( disk.getMega() )

// container
if( !task.container )
throw new ProcessUnrecoverableException("Process `${task.lazyName()}` failed because the container image was not specified")

final cmd = launcher.launchCommand()
final container = Runnable.Container.newBuilder()
.setImageUri( task.container )
Expand Down

0 comments on commit 6419e68

Please sign in to comment.