Skip to content

Commit cc3ff23

Browse files
authored
Merge pull request #673 from maxibor/dev
Fix kraken db loading fromPath
2 parents 85dbda0 + d89b4cc commit cc3ff23

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
1313
- [#631](https://github.com/nf-core/eager/issues/631): - Update minimum Nextflow version to 20.07.1, due to unfortunate bug in Nextflow 20.04.1 causing eager to crash if patch pulled
1414
- Made MultiQC crash behaviour stricter when dealing with large datasets, as reported by @ashildv
1515
- Added note to documentation that when using `--skip_collapse` this will use _paired-end_ alignment mode with mappers when using PE data. `
16+
- [#673](https://github.com/nf-core/eager/pull/673): Fix Kraken database loading when loading from directory instead of compressed file.
1617

1718
### `Dependencies`
1819

main.nf

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3108,14 +3108,16 @@ if (params.run_metagenomic_screening && params.database.endsWith(".tar.gz") && p
31083108
path(dbname) into ch_krakendb
31093109

31103110
script:
3111-
dbname = params.database.tokenize("/")[-1].tokenize(".")[0]
3111+
dbname = ckdb.toString() - '.tar.gz'
31123112
"""
31133113
tar xvzf $ckdb
3114+
mkdir -p $dbname
3115+
mv *.k2d $dbname || echo "nothing to do"
31143116
"""
31153117
}
31163118

31173119
} else if (! params.database.endsWith(".tar.gz") && params.run_metagenomic_screening && params.metagenomic_tool == 'kraken') {
3118-
ch_krakendb = path(params.database)
3120+
ch_krakendb = Channel.fromPath(params.database).first()
31193121
} else {
31203122
ch_krakendb = Channel.empty()
31213123
}

0 commit comments

Comments
 (0)