From a8a6d8b5f8f40d8f1dff111ada2987f1917af9c0 Mon Sep 17 00:00:00 2001 From: Daniel Park Date: Fri, 25 Aug 2023 12:59:07 +0200 Subject: [PATCH] more tolerant if no isolate name defined --- pipes/WDL/tasks/tasks_ncbi_tools.wdl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pipes/WDL/tasks/tasks_ncbi_tools.wdl b/pipes/WDL/tasks/tasks_ncbi_tools.wdl index 64d0328db..8d0cd42ca 100644 --- a/pipes/WDL/tasks/tasks_ncbi_tools.wdl +++ b/pipes/WDL/tasks/tasks_ncbi_tools.wdl @@ -92,7 +92,7 @@ task Fetch_SRA_to_BAM { biosample['accession'] = meta['EXPERIMENT_PACKAGE_SET']['EXPERIMENT_PACKAGE']['SAMPLE']['IDENTIFIERS']['EXTERNAL_ID']['content'] biosample['message'] = 'Successfully loaded' biosample['bioproject_accession'] = meta['EXPERIMENT_PACKAGE_SET']['EXPERIMENT_PACKAGE']['STUDY']['IDENTIFIERS']['EXTERNAL_ID']['content'] - biosample['sample_name'] = biosample['isolate'] + biosample['sample_name'] = biosample.get('isolate', biosample.get('Sample Name', biosample.get('strain', ''))) for k,v in biosample.items(): if v == 'not provided': biosample[k] = ''