-
Notifications
You must be signed in to change notification settings - Fork 442
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bcftools corrupts duplicate GT format fields #1733
Comments
Duplicate tags are not allowed. I am not sure if it is explicitly stated in the VCF specification, but that was the intention. The parsing is done in htslib, ideally it should give a warning and drop the duplicate fields. Obviously, easiest solution is to avoid producing invalid VCFs :) |
pd3
added a commit
to pd3/htslib
that referenced
this issue
Feb 1, 2024
The removal of large tags introduced by b49eea4 and 9db565d could not work correctly, the memmove pointers were wrong! Resolves samtools#1733
jkbonfield
pushed a commit
to pd3/htslib
that referenced
this issue
Mar 14, 2024
The removal of large tags introduced by b49eea4 and 9db565d could not work correctly, the memmove pointers were wrong! Resolves samtools#1733
jkbonfield
pushed a commit
to pd3/htslib
that referenced
this issue
Mar 14, 2024
The removal of large tags introduced by b49eea4 and 9db565d could not work correctly, the memmove pointers were wrong! Resolves samtools#1733
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Running
bcftools
(herefilter
but seems to affect other commands as well) on a VCF with duplicate GT (genotype) FORMAT fields seems to change all but the last GT value. Looks like./.
,0/0
,0/1
,1/1
get converted to0,0
,2,2
,2,4
, and4,4
, respectively. I'm not 100% sure if duplicate GT values are legal, but I would expect an error instead of invalid data. Non-GT fields don't seem to have the problem. I'm using bcftools 1.19, but this can also be reproduced in bcftools 1.12.Minimized test case follows. I would expect the payload to match that of the input.
The text was updated successfully, but these errors were encountered: