@@ -376,17 +376,30 @@ def stderr_stdout_log_path(
376
376
except OSError as e :
377
377
if e .errno == 2 :
378
378
if runtime :
379
- _logger .error ("'%s' not found: %s" , runtime [0 ], str (e ))
379
+ _logger .error (
380
+ "'%s' not found: %s" , runtime [0 ], str (e ), exc_info = runtimeContext .debug
381
+ )
380
382
else :
381
- _logger .error ("'%s' not found: %s" , self .command_line [0 ], str (e ))
383
+ _logger .error (
384
+ "'%s' not found: %s" ,
385
+ self .command_line [0 ],
386
+ str (e ),
387
+ exc_info = runtimeContext .debug ,
388
+ )
382
389
else :
383
- _logger .exception ("Exception while running job" )
390
+ _logger .exception (
391
+ "Exception while running job: %s" , str (e ), exc_info = runtimeContext .debug
392
+ )
384
393
processStatus = "permanentFail"
385
394
except WorkflowException as err :
386
- _logger .error ("[job %s] Job error:\n %s" , self .name , str (err ))
395
+ _logger .error (
396
+ "[job %s] Job error:\n %s" , self .name , str (err ), exc_info = runtimeContext .debug
397
+ )
387
398
processStatus = "permanentFail"
388
- except Exception :
389
- _logger .exception ("Exception while running job" )
399
+ except Exception as err :
400
+ _logger .exception (
401
+ "Exception while running job: %s." , str (err ), exc_info = runtimeContext .debug
402
+ )
390
403
processStatus = "permanentFail"
391
404
if (
392
405
runtimeContext .research_obj is not None
@@ -795,7 +808,7 @@ def run(
795
808
)
796
809
except Exception as err :
797
810
container = "Singularity" if runtimeContext .singularity else "Docker"
798
- _logger .debug ("%s error" , container , exc_info = True )
811
+ _logger .debug ("%s error" , container , exc_info = runtimeContext . debug )
799
812
if docker_is_req :
800
813
raise UnsupportedRequirement (
801
814
f"{ container } is required to run this tool: { str (err )} "
0 commit comments