Skip to content

Commit

Permalink
Merge pull request #439 from nf-core/bowtie-index-cardinality
Browse files Browse the repository at this point in the history
fix cardinality when params.bowtie2_index used
  • Loading branch information
Joon-Klaps authored Aug 27, 2024
2 parents 50992ea + 828c52d commit c293787
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 4 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ jobs:
- "--spades_mode metaviral"
- "--skip_plasmidid false --skip_asciigenome"
- "--additional_annotation ./GCA_009858895.3_ASM985889v3_genomic.gtf.gz"
- "--bowtie2_index ./GCA_009858895.3_ASM985889v3_genomic.200409.bt2.index.tar.gz"
steps:
- name: Check out pipeline code
uses: actions/checkout@v2
Expand All @@ -92,6 +93,11 @@ jobs:
run: |
wget https://ftp.ncbi.nlm.nih.gov/genomes/all/GCA/009/858/895/GCA_009858895.3_ASM985889v3/GCA_009858895.3_ASM985889v3_genomic.gtf.gz
- name: Download prebuild bowtie2 index
if: contains(matrix.parameters, 'bowtie2_index')
run: |
wget https://github.com/nf-core/test-datasets/raw/viralrecon/genome/MN908947.3/GCA_009858895.3_ASM985889v3_genomic.200409.bt2.index.tar.gz
- name: Run pipeline with various parameters
run: |
nextflow run ${GITHUB_WORKSPACE} -profile test,docker ${{ matrix.parameters }} --publish_dir_mode link --outdir ./results
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ Thank you to everyone else that has contributed by reporting bugs, enhancements
- [[PR #417](https://github.com/nf-core/viralrecon/pull/417)] - Allow skipping of Freyja bootstrapping module & freyja module update
- [[PR #434](https://github.com/nf-core/viralrecon/pull/434)] - Add blast result filtering through `min_contig_length` and `min_perc_contig_aligned`.
- [[PR #438](https://github.com/nf-core/viralrecon/pull/438)] - Update fastp container to 0.23.4
- [[PR #439](https://github.com/nf-core/viralrecon/pull/439)] - Fix cardinality issue when using `--bowtie2_index`

### Parameters

Expand Down
8 changes: 4 additions & 4 deletions subworkflows/local/prepare_genome_illumina.nf
Original file line number Diff line number Diff line change
Expand Up @@ -158,12 +158,12 @@ workflow PREPARE_GENOME {
if (bowtie2_index) {
if (bowtie2_index.endsWith('.tar.gz')) {
UNTAR_BOWTIE2_INDEX (
[ [:], bowtie2_index ]
[ [:], file(bowtie2_index) ]
)
ch_bowtie2_index = UNTAR_BOWTIE2_INDEX.out.untar.map { it[1] }
ch_bowtie2_index = UNTAR_BOWTIE2_INDEX.out.untar
ch_versions = ch_versions.mix(UNTAR_BOWTIE2_INDEX.out.versions)
} else {
ch_bowtie2_index = Channel.value(file(bowtie2_index))
ch_bowtie2_index = [ [:], file(bowtie2_index) ]
}
} else {
BOWTIE2_BUILD (
Expand Down Expand Up @@ -246,7 +246,7 @@ workflow PREPARE_GENOME {
gff = ch_gff // path: genome.gff
fai = ch_fai // path: genome.fai
chrom_sizes = ch_chrom_sizes // path: genome.sizes
bowtie2_index = ch_bowtie2_index // path: bowtie2/index/
bowtie2_index = ch_bowtie2_index // channel: [ [:], bowtie2/index/ ]
primer_bed = ch_primer_bed // path: primer.bed
primer_collapsed_bed = ch_primer_collapsed_bed // path: primer.collapsed.bed
primer_fasta = ch_primer_fasta // path: primer.fasta
Expand Down

0 comments on commit c293787

Please sign in to comment.