Skip to content

bcftools annotate --collapse all -c +ID does not annotate anything in 1.16 #1808

Closed
@danilovkiri

Description

@danilovkiri

Archive.zip

Hi.

When upgrading from bcftools 1.11 to bcftools 1.16 I noticed a completely erroneous behaviour.
Running bcftools 1.11

bcftools annotate --collapse all -c +ID -a ./dbsnp-155-split.vcf.gz -r chrM ./sample.gatk_annotatedM.vcf.gz --output-type z -o sample.annotatedM_1.11.vcf.gz --threads 16

behaves as expected populating ID field in the VCF entries with unknown (.) ALT allele and uncalled or HOM-REF genotypes.

Running the same command using bcftools 1.16 results in zero HOM-REF entries annotated with ID from the external annotation resource.

For instance, the source entry

chrM	1943	.	A	.	24.76	.	AN=50;DP=3039	GT:AD:DP:RGQ	0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0:3038,1:3039:4

is annotated by bcftools 1.11 as

chrM	1943	rs1556422584	A	.	24.76	.	AN=50;DP=3039	GT:AD:DP:RGQ	0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0:3038,1:3039:4

while annotation by bcftools 1.16 results in no ID field annotation

chrM	1943	.	A	.	24.76	.	AN=50;DP=3039	GT:AD:DP:RGQ	0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0/0:3038,1:3039:4

This behaviour is reproducible in all canonical chromosomes, haploid and diploid genotypes (as well as other genotype ploidy values). I also noticed the same behavior in bcftools v1.15.1.

The test files are supplied in an archive with file names stored as used in the provided command.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions