Skip to content

bcftools consensus always output "Applied 0 variants" and does not change the reference sequence. #2260

@shiro-kur

Description

@shiro-kur

Hello. There is something wrong with "bcftools consensus" recently.

Finally I tried to convert some nucleotides in simple files below, as examples.
Can you reproduce these errors? and How can we solve the problem.

$ bcftools --version
bcftools 1.20
Using htslib 1.20
Copyright (C) 2024 Genome Research Ltd.
License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

$ zcat ex.vcf.gz
##fileformat=VCFv4.1
##contig=<ID=chr1,length=4>
#CHROM POS ID REF ALT QUAL FILTER INFO
chr1 1 . A T . . .

$ cat ex.fa

chr1
ATGC

$ bcftools consensus -f ex.fa ./ex.vcf.gz -o ./ex2.fa
Applied 0 variants

(bcftools) [shiro2@rc026 ""]$ cat ex2.fa

chr1
ATGC

The vcf files was compressed and indexed as followings.
$ bgzip ex.vcf
$ bcftools index ex.vcf.gz

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions