diff --git a/protected/gatk-package-distribution/pom.xml b/protected/gatk-package-distribution/pom.xml index e44ecc15d..c48ffad7b 100644 --- a/protected/gatk-package-distribution/pom.xml +++ b/protected/gatk-package-distribution/pom.xml @@ -48,7 +48,7 @@ - samtools + com.github.samtools htsjdk diff --git a/protected/gatk-queue-extensions-distribution/pom.xml b/protected/gatk-queue-extensions-distribution/pom.xml index 44018ec4e..6b8e52749 100644 --- a/protected/gatk-queue-extensions-distribution/pom.xml +++ b/protected/gatk-queue-extensions-distribution/pom.xml @@ -42,7 +42,7 @@ log4j - picard + com.github.broadinstitute picard - picard + com.github.broadinstitute picard diff --git a/protected/gatk-tools-protected/src/main/java/org/broadinstitute/gatk/utils/gvcf/HomRefBlock.java b/protected/gatk-tools-protected/src/main/java/org/broadinstitute/gatk/utils/gvcf/HomRefBlock.java index 8e2308590..6e27a5a63 100644 --- a/protected/gatk-tools-protected/src/main/java/org/broadinstitute/gatk/utils/gvcf/HomRefBlock.java +++ b/protected/gatk-tools-protected/src/main/java/org/broadinstitute/gatk/utils/gvcf/HomRefBlock.java @@ -187,7 +187,10 @@ final class HomRefBlock { } public VCFHeaderLine toVCFHeaderLine() { - return new VCFHeaderLine("GVCFBlock", "minGQ=" + getGQLowerBound() + "(inclusive),maxGQ=" + getGQUpperBound() + "(exclusive)"); + // Need to uniquify the key for the header line using the min/max GQ, since + // VCFHeader does not allow lines with duplicate keys. + final String key = String.format("GVCFBlock%d-%d", getGQLowerBound(), getGQUpperBound()); + return new VCFHeaderLine(key, "minGQ=" + getGQLowerBound() + "(inclusive),maxGQ=" + getGQUpperBound() + "(exclusive)"); } /** diff --git a/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/beagle/BeagleIntegrationTest.java b/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/beagle/BeagleIntegrationTest.java index 7f84b792d..30ae63869 100644 --- a/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/beagle/BeagleIntegrationTest.java +++ b/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/beagle/BeagleIntegrationTest.java @@ -67,7 +67,7 @@ public class BeagleIntegrationTest extends WalkerTest { "--beagleR2:BEAGLE " + beagleValidationDataLocation + "inttestbgl.r2 " + "--beagleProbs:BEAGLE " + beagleValidationDataLocation + "inttestbgl.gprobs " + "--beaglePhased:BEAGLE " + beagleValidationDataLocation + "inttestbgl.phased " + - "-o %s --no_cmdline_in_header -U LENIENT_VCF_PROCESSING", 1, Arrays.asList("989449fa3e262b88ba126867fa3ad9fb")); + "-o %s --no_cmdline_in_header -U LENIENT_VCF_PROCESSING", 1, Arrays.asList("1c4f2fed1d452368fa4dfe3e209ebb57")); spec.disableShadowBCF(); executeTest("test BeagleOutputToVCF", spec); } diff --git a/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/haplotypecaller/HaplotypeCallerGVCFIntegrationTest.java b/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/haplotypecaller/HaplotypeCallerGVCFIntegrationTest.java index d18f24d20..42c8c6285 100644 --- a/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/haplotypecaller/HaplotypeCallerGVCFIntegrationTest.java +++ b/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/haplotypecaller/HaplotypeCallerGVCFIntegrationTest.java @@ -77,10 +77,10 @@ public class HaplotypeCallerGVCFIntegrationTest extends WalkerTest { // this functionality can be adapted to provide input data for whatever you might want in your data tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.NONE, PCRFreeIntervals, "3e440b1b755a21d7bd3ecb093af8f43e"}); tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.BP_RESOLUTION, PCRFreeIntervals, "ebe078a1e209a5b231aeeba6deebcb8a"}); - tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.GVCF, PCRFreeIntervals, "b6d3cbc4eecb8d295898d94335be54c2"}); + tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.GVCF, PCRFreeIntervals, "2ad9b5d87416c466292c2b97480e1f5c"}); tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.NONE, WExIntervals, "6ca1e6cb78157273a4a96ba00e6d4713"}); tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.BP_RESOLUTION, WExIntervals, "8645c191ca5dbbae8dcb1389717f985a"}); - tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.GVCF, WExIntervals, "82f2efd1e9ec6197344d9001b653c7fb"}); + tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.GVCF, WExIntervals, "9606db453f9e8beae27669afcea288a1"}); return tests.toArray(new Object[][]{}); } @@ -96,11 +96,11 @@ public class HaplotypeCallerGVCFIntegrationTest extends WalkerTest { // this functionality can be adapted to provide input data for whatever you might want in your data tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.NONE, PCRFreeIntervals, "92c7415dd1a5793161032d839b88fc28"}); tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.BP_RESOLUTION, PCRFreeIntervals, "b90d7c900ff4a8b5e58d6bd4ad64d750"}); - tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.GVCF, PCRFreeIntervals, "7abdd32f0d11cbf43f5bceeca946a428"}); + tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.GVCF, PCRFreeIntervals, "8a1dcc091cb28e1fbbc86a1de85dfd4c"}); tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.NONE, WExIntervals, "7e84e4562d8df6e593e58f017f697355"}); tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.BP_RESOLUTION, WExIntervals, "307ce5ada7c68e2f08664937bafa6281"}); - final String NA12878bandedResolutionMD5 = "74f728f1c42e3014776197606ddf5116"; + final String NA12878bandedResolutionMD5 = "d51df38ad52cf2b0ecbce362e60fb24e"; tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.GVCF, WExIntervals, NA12878bandedResolutionMD5}); tests.add(new Object[]{NA12878_WEx + " -I " + privateTestDir + "NA20313.highCoverageRegion.bam -sn NA12878", ReferenceConfidenceMode.GVCF, WExIntervals, NA12878bandedResolutionMD5}); @@ -119,10 +119,10 @@ public class HaplotypeCallerGVCFIntegrationTest extends WalkerTest { // this functionality can be adapted to provide input data for whatever you might want in your data tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.NONE, PCRFreeIntervals, "f441aab92b07591281fa44748b7bd71e"}); tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.BP_RESOLUTION, PCRFreeIntervals, "d54d7988552a13de90977ba06b094b74"}); - tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.GVCF, PCRFreeIntervals, "a1e2f104c50c89b9c562045daebf07ca"}); + tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.GVCF, PCRFreeIntervals, "c3c12414059390f3d6e3e533502c1869"}); tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.NONE, WExIntervals, "91164cf1247f5b187ad133b280aa1fd2"}); tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.BP_RESOLUTION, WExIntervals, "b5c1b79550a8d8bb479895e2be38d945"}); - tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.GVCF, WExIntervals, "48b737b4f1739edd275eb347c6ca5997"}); + tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.GVCF, WExIntervals, "79e913ab2ddf19b3cae75f2da9394239"}); return tests.toArray(new Object[][]{}); } @@ -137,10 +137,10 @@ public class HaplotypeCallerGVCFIntegrationTest extends WalkerTest { // this functionality can be adapted to provide input data for whatever you might want in your data tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.NONE, PCRFreeIntervals, "081d943a092b7ad71d1f1fa6ec191ace"}); tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.BP_RESOLUTION, PCRFreeIntervals, "93f95c7a51741f8e527f1308ffd91052"}); - tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.GVCF, PCRFreeIntervals, "a6e858123e40efece5a9a43a0c05bdb2"}); + tests.add(new Object[]{NA12878_PCRFREE, ReferenceConfidenceMode.GVCF, PCRFreeIntervals, "1f2e5b5c06cb6d1196315c4308421f6d"}); tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.NONE, WExIntervals, "3d8f4f849df0b9cddb1ec61279e91a83"}); tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.BP_RESOLUTION, WExIntervals, "1fbe1435b860400ecae3115141453c9a"}); - tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.GVCF, WExIntervals, "af7f383fd675d2edfaba7f67a96e67c7"}); + tests.add(new Object[]{NA12878_WEx, ReferenceConfidenceMode.GVCF, WExIntervals, "fe9e1992cc28b798dd3ee66aaba726aa"}); return tests.toArray(new Object[][]{}); } @@ -254,7 +254,7 @@ public class HaplotypeCallerGVCFIntegrationTest extends WalkerTest { public void testWrongGVCFNonVariantRecordOrderBugFix() { final String commandLine = String.format("-T HaplotypeCaller --pcr_indel_model NONE -pairHMMSub %s %s -R %s -I %s -L %s -ERC GVCF --no_cmdline_in_header -variant_index_type %s -variant_index_parameter %d", HMM_SUB_IMPLEMENTATION, ALWAYS_LOAD_VECTOR_HMM, b37KGReference, WRONG_GVCF_RECORD_ORDER_BUGFIX_BAM, WRONG_GVCF_RECORD_ORDER_BUGFIX_INTERVALS, GATKVCFUtils.DEFAULT_GVCF_INDEX_TYPE, GATKVCFUtils.DEFAULT_GVCF_INDEX_PARAMETER); - final WalkerTestSpec spec = new WalkerTestSpec(commandLine + " -o %s", Arrays.asList("ae90a1b5c40f19df38e8ac58c3844ed5")); + final WalkerTestSpec spec = new WalkerTestSpec(commandLine + " -o %s", Arrays.asList("7fa0578150ea8ef333cb141f78cf4a5a")); spec.disableShadowBCF(); executeTest("testMissingGVCFIndexingStrategyException", spec); } @@ -271,7 +271,7 @@ public class HaplotypeCallerGVCFIntegrationTest extends WalkerTest { public void testNoCallGVCFMissingPLsBugFix() { final String commandLine = String.format("-T HaplotypeCaller --pcr_indel_model NONE -pairHMMSub %s %s -R %s -I %s -L %s -ERC GVCF --no_cmdline_in_header -variant_index_type %s -variant_index_parameter %d", HMM_SUB_IMPLEMENTATION, ALWAYS_LOAD_VECTOR_HMM, b37KGReference, NOCALL_GVCF_BUGFIX_BAM, NOCALL_GVCF_BUGFIX_INTERVALS, GATKVCFUtils.DEFAULT_GVCF_INDEX_TYPE, GATKVCFUtils.DEFAULT_GVCF_INDEX_PARAMETER); - final WalkerTestSpec spec = new WalkerTestSpec(commandLine + " -o %s", Arrays.asList("bf6325fbc06c80893f3170668cfbed06")); + final WalkerTestSpec spec = new WalkerTestSpec(commandLine + " -o %s", Arrays.asList("befa4bf150099b3faf44130a6c9cdbb9")); spec.disableShadowBCF(); executeTest("testNoCallGVCFMissingPLsBugFix", spec); } diff --git a/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/validation/ValidationSiteSelectorIntegrationTest.java b/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/validation/ValidationSiteSelectorIntegrationTest.java index 4c385ab5a..cbe3408de 100644 --- a/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/validation/ValidationSiteSelectorIntegrationTest.java +++ b/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/tools/walkers/validation/ValidationSiteSelectorIntegrationTest.java @@ -84,7 +84,7 @@ public class ValidationSiteSelectorIntegrationTest extends WalkerTest { WalkerTestSpec spec = new WalkerTestSpec( baseTestString(sampleNone + freqUnif + "--variant " + testfile), 1, - Arrays.asList("658c70cbb93faed8ca18e51cd6dd593f") + Arrays.asList("19fe0e3297bfd502911608490222a2fd") ); executeTest("testNoSampleSelectionFreqUniform--" + testfile, spec); @@ -96,7 +96,7 @@ public class ValidationSiteSelectorIntegrationTest extends WalkerTest { WalkerTestSpec spec = new WalkerTestSpec( baseTestString(sampleNone + freqAF + "--variant " + testfile), 1, - Arrays.asList("90411433ea42846352b767da735af53b") + Arrays.asList("91a7f3bf452241040646e61ee6ab1a23") ); executeTest("testNoSampleSelectionFreqAF--" + testfile, spec); @@ -108,7 +108,7 @@ public class ValidationSiteSelectorIntegrationTest extends WalkerTest { WalkerTestSpec spec = new WalkerTestSpec( baseTestString(sampleGT + freqUnif + "--variant " + testfile), 1, - Arrays.asList("2afabd447185cf017f60c85380902117") + Arrays.asList("faae3baf1feb76877fcb81c01b5d44f3") ); executeTest("testPolyGTFreqUniform--" + testfile, spec); @@ -120,7 +120,7 @@ public class ValidationSiteSelectorIntegrationTest extends WalkerTest { WalkerTestSpec spec = new WalkerTestSpec( baseTestString(sampleGT + freqAF + "--variant " + testfile), 1, - Arrays.asList("381e1a2f0e1908b4d7cba5d6361cf5aa") + Arrays.asList("d2ba4e3e76f87e2c1a12d82e7a3dc595") ); executeTest("testPolyGTFreqAF--" + testfile, spec); @@ -132,7 +132,7 @@ public class ValidationSiteSelectorIntegrationTest extends WalkerTest { WalkerTestSpec spec = new WalkerTestSpec( baseTestString(sampleGL + freqAF + "--variant " + testfile), 1, - Arrays.asList("381e1a2f0e1908b4d7cba5d6361cf5aa") + Arrays.asList("d2ba4e3e76f87e2c1a12d82e7a3dc595") ); executeTest("testPolyGLFreqAF--" + testfile, spec); diff --git a/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/utils/gvcf/HomRefBlockUnitTest.java b/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/utils/gvcf/HomRefBlockUnitTest.java index 59da23416..88b5b6bbc 100644 --- a/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/utils/gvcf/HomRefBlockUnitTest.java +++ b/protected/gatk-tools-protected/src/test/java/org/broadinstitute/gatk/utils/gvcf/HomRefBlockUnitTest.java @@ -167,4 +167,10 @@ public class HomRefBlockUnitTest extends BaseTest { final VariantContext testVC = new VariantContextBuilder(vc).chr(contig).start(pos).stop(pos).make(); Assert.assertEquals(band.isContiguous(testVC), expected); } + + @Test + public void testToVCFHeaderLine() { + final HomRefBlock band = new HomRefBlock(vc, 10, 20, HomoSapiensConstants.DEFAULT_PLOIDY); + Assert.assertEquals(band.toVCFHeaderLine().getKey(), "GVCFBlock10-20", "Wrong key for HomRefBlock " + band); + } } diff --git a/public/external-example/pom.xml b/public/external-example/pom.xml index 67535a788..46bdab5d2 100644 --- a/public/external-example/pom.xml +++ b/public/external-example/pom.xml @@ -155,7 +155,7 @@ - samtools:htsjdk + com.github.samtools:htsjdk ** diff --git a/public/gatk-engine/src/test/java/org/broadinstitute/gatk/engine/datasources/providers/IntervalReferenceOrderedViewUnitTest.java b/public/gatk-engine/src/test/java/org/broadinstitute/gatk/engine/datasources/providers/IntervalReferenceOrderedViewUnitTest.java index f77b6613a..791046a77 100644 --- a/public/gatk-engine/src/test/java/org/broadinstitute/gatk/engine/datasources/providers/IntervalReferenceOrderedViewUnitTest.java +++ b/public/gatk-engine/src/test/java/org/broadinstitute/gatk/engine/datasources/providers/IntervalReferenceOrderedViewUnitTest.java @@ -27,7 +27,7 @@ package org.broadinstitute.gatk.engine.datasources.providers; import htsjdk.samtools.util.PeekableIterator; import htsjdk.samtools.SAMFileHeader; -import htsjdk.tribble.BasicFeature; +import htsjdk.tribble.SimpleFeature; import htsjdk.tribble.Feature; import org.broadinstitute.gatk.utils.BaseTest; import org.broadinstitute.gatk.utils.commandline.RodBinding; @@ -109,35 +109,35 @@ public class IntervalReferenceOrderedViewUnitTest extends BaseTest { public void initializeTests() { final List handPickedFeatures = new ArrayList(); - handPickedFeatures.add(new BasicFeature(contig, 1, 1)); - handPickedFeatures.add(new BasicFeature(contig, 2, 5)); - handPickedFeatures.add(new BasicFeature(contig, 4, 4)); - handPickedFeatures.add(new BasicFeature(contig, 6, 6)); - handPickedFeatures.add(new BasicFeature(contig, 9, 10)); - handPickedFeatures.add(new BasicFeature(contig, 10, 10)); - handPickedFeatures.add(new BasicFeature(contig, 10, 11)); - handPickedFeatures.add(new BasicFeature(contig, 13, 20)); + handPickedFeatures.add(new SimpleFeature(contig, 1, 1)); + handPickedFeatures.add(new SimpleFeature(contig, 2, 5)); + handPickedFeatures.add(new SimpleFeature(contig, 4, 4)); + handPickedFeatures.add(new SimpleFeature(contig, 6, 6)); + handPickedFeatures.add(new SimpleFeature(contig, 9, 10)); + handPickedFeatures.add(new SimpleFeature(contig, 10, 10)); + handPickedFeatures.add(new SimpleFeature(contig, 10, 11)); + handPickedFeatures.add(new SimpleFeature(contig, 13, 20)); createTestsForFeatures(handPickedFeatures); // test in the present of a large spanning element { List oneLargeSpan = new ArrayList(handPickedFeatures); - oneLargeSpan.add(new BasicFeature(contig, 1, 30)); + oneLargeSpan.add(new SimpleFeature(contig, 1, 30)); createTestsForFeatures(oneLargeSpan); } // test in the presence of a partially spanning element { List partialSpanStart = new ArrayList(handPickedFeatures); - partialSpanStart.add(new BasicFeature(contig, 1, 6)); + partialSpanStart.add(new SimpleFeature(contig, 1, 6)); createTestsForFeatures(partialSpanStart); } // test in the presence of a partially spanning element at the end { List partialSpanEnd = new ArrayList(handPickedFeatures); - partialSpanEnd.add(new BasicFeature(contig, 10, 30)); + partialSpanEnd.add(new SimpleFeature(contig, 10, 30)); createTestsForFeatures(partialSpanEnd); } diff --git a/public/gatk-queue-extensions-public/pom.xml b/public/gatk-queue-extensions-public/pom.xml index b2d833d50..287479a94 100644 --- a/public/gatk-queue-extensions-public/pom.xml +++ b/public/gatk-queue-extensions-public/pom.xml @@ -40,7 +40,7 @@ log4j - picard + com.github.broadinstitute picard - 1.128.1696 - 1.128.1678 + 1.132 + 1.131 @@ -67,7 +67,7 @@ 1.0-r139 - samtools + com.github.samtools htsjdk ${htsjdk.version} @@ -82,7 +82,7 @@ - picard + com.github.broadinstitute picard ${picard.version} diff --git a/public/gatk-tools-public/src/test/java/org/broadinstitute/gatk/tools/walkers/readutils/SplitSamFileIntegrationTest.java b/public/gatk-tools-public/src/test/java/org/broadinstitute/gatk/tools/walkers/readutils/SplitSamFileIntegrationTest.java index 5a5258b3d..1c2e6bbac 100644 --- a/public/gatk-tools-public/src/test/java/org/broadinstitute/gatk/tools/walkers/readutils/SplitSamFileIntegrationTest.java +++ b/public/gatk-tools-public/src/test/java/org/broadinstitute/gatk/tools/walkers/readutils/SplitSamFileIntegrationTest.java @@ -43,9 +43,9 @@ public class SplitSamFileIntegrationTest extends WalkerTest { " --outputRoot " + prefix, Collections.emptyList() ); - addSplitOutput(spec, prefix, "NA12878", "b1a57327a3f0bdbe167dbc7d547f1247"); - addSplitOutput(spec, prefix, "NA12891", "3bb331fd468fc91c548f38857473f399"); - addSplitOutput(spec, prefix, "NA12892", "ac61ae9cd168ac15e3a03fe7ab51fb22"); + addSplitOutput(spec, prefix, "NA12878", "ffb8a1e76798fa78c9ffe46abc02e92f"); + addSplitOutput(spec, prefix, "NA12891", "42154dc36451dfe98922a579d329bbe2"); + addSplitOutput(spec, prefix, "NA12892", "6abb5d11e615310987da22212dd9fc84"); executeTest("testSplitSamFile", spec); } diff --git a/public/gatk-utils/pom.xml b/public/gatk-utils/pom.xml index e0e2fad72..cee26590f 100644 --- a/public/gatk-utils/pom.xml +++ b/public/gatk-utils/pom.xml @@ -22,7 +22,7 @@ - samtools + com.github.samtools htsjdk diff --git a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/beagle/BeagleFeature.java b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/beagle/BeagleFeature.java index bd9e4ef4c..673885a1b 100644 --- a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/beagle/BeagleFeature.java +++ b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/beagle/BeagleFeature.java @@ -44,15 +44,22 @@ public class BeagleFeature implements Feature { Allele AlleleA; Allele AlleleB; - + @Override public String getChr() { + return getContig(); + } + + @Override + public String getContig() { return chr; } + @Override public int getStart() { return start; } + @Override public int getEnd() { return end; } diff --git a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/hapmap/RawHapMapFeature.java b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/hapmap/RawHapMapFeature.java index a9b878847..e760aaa83 100644 --- a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/hapmap/RawHapMapFeature.java +++ b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/hapmap/RawHapMapFeature.java @@ -106,6 +106,14 @@ public class RawHapMapFeature implements Feature { * @return a string representing the contig */ public String getChr() { + return getContig(); + } + + /** + * get the contig value + * @return a string representing the contig + */ + public String getContig() { return contig; } diff --git a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/refseq/RefSeqFeature.java b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/refseq/RefSeqFeature.java index 97ff961d9..0e7b80d75 100644 --- a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/refseq/RefSeqFeature.java +++ b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/refseq/RefSeqFeature.java @@ -309,14 +309,22 @@ public class RefSeqFeature implements Transcript, Feature { this.name = name; } + @Override public String getChr() { + return getContig(); + } + + @Override + public String getContig() { return transcript_interval.getContig(); } + @Override public int getStart() { return transcript_interval.getStart(); } + @Override public int getEnd() { return transcript_interval.getStop(); } diff --git a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/sampileup/SAMPileupFeature.java b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/sampileup/SAMPileupFeature.java index 89f168b67..501a7b597 100644 --- a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/sampileup/SAMPileupFeature.java +++ b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/sampileup/SAMPileupFeature.java @@ -66,7 +66,13 @@ public class SAMPileupFeature implements Feature { */ SAMPileupFeature() {} + @Override public String getChr() { + return getContig(); + } + + @Override + public String getContig() { return contig; } @@ -74,6 +80,7 @@ public class SAMPileupFeature implements Feature { this.contig = chr; } + @Override public int getStart() { return start; } @@ -82,6 +89,7 @@ public class SAMPileupFeature implements Feature { this.start = start; } + @Override public int getEnd() { return stop; } diff --git a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/samread/SAMReadFeature.java b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/samread/SAMReadFeature.java index 129ae6e66..857871cfd 100644 --- a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/samread/SAMReadFeature.java +++ b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/samread/SAMReadFeature.java @@ -150,6 +150,14 @@ public class SAMReadFeature implements Feature { * @return Aligned contig name. */ public String getChr() { + return getContig(); + } + + /** + * An alias for getReferenceName, required by Feature interface. + * @return Aligned contig name. + */ + public String getContig() { return getReferenceName(); } diff --git a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/table/TableFeature.java b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/table/TableFeature.java index 58b06c954..680c13f92 100644 --- a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/table/TableFeature.java +++ b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/codecs/table/TableFeature.java @@ -53,6 +53,11 @@ public class TableFeature implements Feature { @Override public String getChr() { + return getContig(); + } + + @Override + public String getContig() { return position.getContig(); } diff --git a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/refdata/utils/GATKFeature.java b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/refdata/utils/GATKFeature.java index e638ab48e..428055f0b 100644 --- a/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/refdata/utils/GATKFeature.java +++ b/public/gatk-utils/src/main/java/org/broadinstitute/gatk/utils/refdata/utils/GATKFeature.java @@ -82,7 +82,13 @@ public abstract class GATKFeature implements Feature, HasGenomeLocation { /** Return the features reference sequence name, e.g chromosome or contig */ @Override public String getChr() { - return feature.getChr(); + return getContig(); + } + + /** Return the features reference sequence name, e.g chromosome or contig */ + @Override + public String getContig() { + return feature.getContig(); } /** Return the start position in 1-based coordinates (first base is 1) */ diff --git a/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/GenomeLocParserUnitTest.java b/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/GenomeLocParserUnitTest.java index d413633b6..c3f5bbd88 100644 --- a/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/GenomeLocParserUnitTest.java +++ b/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/GenomeLocParserUnitTest.java @@ -29,8 +29,8 @@ package org.broadinstitute.gatk.utils; import htsjdk.samtools.SAMFileHeader; import htsjdk.samtools.SAMSequenceDictionary; import htsjdk.samtools.SAMSequenceRecord; -import htsjdk.tribble.BasicFeature; import htsjdk.tribble.Feature; +import htsjdk.tribble.SimpleFeature; import org.broadinstitute.gatk.utils.BaseTest; import org.broadinstitute.gatk.utils.exceptions.ReviewedGATKException; import org.broadinstitute.gatk.utils.exceptions.UserException; @@ -421,7 +421,7 @@ public class GenomeLocParserUnitTest extends BaseTest { @Test public void testCreationFromFeature() { - final Feature feature = new BasicFeature("chr1", 1, 5); + final Feature feature = new SimpleFeature("chr1", 1, 5); final GenomeLoc loc = genomeLocParser.createGenomeLoc(feature); Assert.assertEquals(loc.getContig(), feature.getChr()); Assert.assertEquals(loc.getStart(), feature.getStart()); diff --git a/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/interval/IntervalUtilsUnitTest.java b/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/interval/IntervalUtilsUnitTest.java index 88b17c766..48c6cb480 100644 --- a/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/interval/IntervalUtilsUnitTest.java +++ b/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/interval/IntervalUtilsUnitTest.java @@ -1046,7 +1046,18 @@ public class IntervalUtilsUnitTest extends BaseTest { }; } - @Test(dataProvider="invalidIntervalTestData") + /* + * This test is disabled because its assumption that we will not throw an error + * upon parsing invalid Picard intervals is no longer true, as htsjdk has added + * extra protection against invalid intervals to IntervalList.add(). + * + * We should reconsider our decision in IntervalUtils.intervalFileToList() to + * silently ignore invalid intervals when parsing Picard interval files, as it's + * inconsistent with the way we handle invalid intervals for GATK interval files + * (throw a UserException, covered by testInvalidGATKFileIntervalHandling() below), + * and update this test accordingly. + */ + @Test(dataProvider="invalidIntervalTestData", enabled = false) public void testInvalidPicardIntervalHandling(GenomeLocParser genomeLocParser, String contig, int intervalStart, int intervalEnd ) throws Exception { diff --git a/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/refdata/utils/FlashBackIteratorUnitTest.java b/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/refdata/utils/FlashBackIteratorUnitTest.java index 34129abc8..ee5f17ef9 100644 --- a/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/refdata/utils/FlashBackIteratorUnitTest.java +++ b/public/gatk-utils/src/test/java/org/broadinstitute/gatk/utils/refdata/utils/FlashBackIteratorUnitTest.java @@ -316,6 +316,11 @@ class FakeRODatum extends GATKFeature implements ReferenceOrderedDatum { @Override public String getChr() { + return getContig(); + } + + @Override + public String getContig() { return location.getContig(); } diff --git a/public/repo/picard/picard/1.128.1678/picard-1.128.1678.jar b/public/repo/picard/picard/1.128.1678/picard-1.128.1678.jar deleted file mode 100644 index 25c3620a8..000000000 Binary files a/public/repo/picard/picard/1.128.1678/picard-1.128.1678.jar and /dev/null differ diff --git a/public/repo/picard/picard/1.128.1678/picard-1.128.1678.pom b/public/repo/picard/picard/1.128.1678/picard-1.128.1678.pom deleted file mode 100644 index 33426f07c..000000000 --- a/public/repo/picard/picard/1.128.1678/picard-1.128.1678.pom +++ /dev/null @@ -1,34 +0,0 @@ - - - 4.0.0 - picard - picard - 1.128.1678 - picard - - - samtools - htsjdk - 1.128.1696 - - - - org.apache.ant - ant - 1.8.2 - - - org.apache.ant - ant-launcher - - - - - com.sun - tools.jar - 1.5 - system - ${java.home}/../lib/tools.jar - - - diff --git a/public/repo/samtools/htsjdk/1.128.1696/htsjdk-1.128.1696.jar b/public/repo/samtools/htsjdk/1.128.1696/htsjdk-1.128.1696.jar deleted file mode 100644 index 9425b73ff..000000000 Binary files a/public/repo/samtools/htsjdk/1.128.1696/htsjdk-1.128.1696.jar and /dev/null differ diff --git a/public/repo/samtools/htsjdk/1.128.1696/htsjdk-1.128.1696.pom b/public/repo/samtools/htsjdk/1.128.1696/htsjdk-1.128.1696.pom deleted file mode 100644 index 0932ccb78..000000000 --- a/public/repo/samtools/htsjdk/1.128.1696/htsjdk-1.128.1696.pom +++ /dev/null @@ -1,27 +0,0 @@ - - - 4.0.0 - samtools - htsjdk - 1.128.1696 - htsjdk - - - org.testng - testng - 5.5 - jdk15 - - - org.xerial.snappy - snappy-java - 1.0.3-rc3 - - - - com.google.code.cofoja - cofoja - 1.0-r139 - - -