From 6f9d58f68bc0e3833577450e636116e8918d74e8 Mon Sep 17 00:00:00 2001 From: Chris Norman Date: Wed, 1 Jun 2022 09:06:58 -0400 Subject: [PATCH 1/2] Fix code GenotypeConcordance code that is sensitive to Allele ordering in sets. --- src/main/java/picard/vcf/GenotypeConcordance.java | 3 ++- .../vcf/spanningDeletionCallset_vs_spanningDeletionTruth.vcf | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/picard/vcf/GenotypeConcordance.java b/src/main/java/picard/vcf/GenotypeConcordance.java index ff8218cd78..bbd32ed9df 100644 --- a/src/main/java/picard/vcf/GenotypeConcordance.java +++ b/src/main/java/picard/vcf/GenotypeConcordance.java @@ -71,6 +71,7 @@ import java.util.HashMap; import java.util.HashSet; import java.util.Iterator; +import java.util.LinkedHashSet; import java.util.List; import java.util.Map; import java.util.Optional; @@ -534,7 +535,7 @@ private void writeVcfTuple(final VcfTuple tuple, final VariantContextWriter writ final List callAlleles = alleles.callAlleles(); // Get the alleles present at this site for both samples to use for the output variant context, but remove no calls. - final Set siteAlleles = new HashSet<>(); + final Set siteAlleles = new LinkedHashSet<>(); siteAlleles.addAll(allAlleles); siteAlleles.remove(Allele.NO_CALL); diff --git a/testdata/picard/vcf/spanningDeletionCallset_vs_spanningDeletionTruth.vcf b/testdata/picard/vcf/spanningDeletionCallset_vs_spanningDeletionTruth.vcf index c16d5e8de9..31f9b677ce 100644 --- a/testdata/picard/vcf/spanningDeletionCallset_vs_spanningDeletionTruth.vcf +++ b/testdata/picard/vcf/spanningDeletionCallset_vs_spanningDeletionTruth.vcf @@ -90,5 +90,5 @@ ##source=htsbox-pileup-r315 #CHROM POS ID REF ALT QUAL FILTER INFO FORMAT call truth chr1 18359359 . A G,* 30 . CONC_ST=TP GT:AD 2|1:0,1,1 2|1:0,1,1 -chr1 18359383 . AAAGGAAGG GAAGGAAGG,A,*,AAAGGAAGGAAGG 216.73 . CONC_ST=FP,FN GT:AD:DP:GQ:MBQ:MFRL:MMQ:MPOS:PL 2/4:0,5,3:8:76:30,30:0,418,443:60,60:13,18:254,76,159,185,0,175 3|1:0,1,1 +chr1 18359383 . AAAGGAAGG *,GAAGGAAGG,A,AAAGGAAGGAAGG 216.73 . CONC_ST=FP,FN GT:AD:DP:GQ:MBQ:MFRL:MMQ:MPOS:PL 3/4:0,5,3:8:76:30,30:0,418,443:60,60:13,18:254,76,159,185,0,175 1|2:0,1,1 chrX 27587985 . AATATATAT A,* 6939.56 . CONC_ST=FP,FN GT:AD:DP:GQ:PL 0/2:16,16,0,0:32:99:522,0,592,571,640,1210,571,640,1210,1210 1/1:0,20 From 3f0957322f44709444816baa03deba7a8eed6188 Mon Sep 17 00:00:00 2001 From: Chris Norman Date: Tue, 7 Jun 2022 08:34:58 -0400 Subject: [PATCH 2/2] Upgrade to htsjdk 3.0.0. --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 28e9f12d90..d924a08e1d 100644 --- a/build.gradle +++ b/build.gradle @@ -65,7 +65,7 @@ def ensureBuildPrerequisites(buildPrerequisitesMessage) { ensureBuildPrerequisites(buildPrerequisitesMessage) -final htsjdkVersion = System.getProperty('htsjdk.version', '2.24.1') +final htsjdkVersion = System.getProperty('htsjdk.version', '3.0.0') final googleNio = 'com.google.cloud:google-cloud-nio:0.123.25' // Get the jdk files we need to run javaDoc. We need to use these during compile, testCompile,