Skip to content

Commit 882abec

Browse files
committed
Merge discvr-25.3 to discvr-25.7
2 parents 1178c3a + ea3d4f5 commit 882abec

File tree

5 files changed

+32
-2
lines changed

5 files changed

+32
-2
lines changed

SequenceAnalysis/api-src/org/labkey/api/sequenceanalysis/run/AbstractGatk4Wrapper.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ public List<String> getBaseArgs(@Nullable String toolName)
9191
args.add(SequencePipelineService.get().getJavaFilepath());
9292
args.addAll(SequencePipelineService.get().getJavaOpts(_maxRamOverride));
9393
args.add("-DGATK_STACKTRACE_ON_USER_EXCEPTION=true");
94+
args.add("-Dsamjdk.optimistic_vcf_4_4=true");
9495
args.add("-jar");
9596
args.add(getJAR().getPath());
9697

SequenceAnalysis/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ dependencies {
135135
BuildUtils.addExternalDependency(
136136
project,
137137
new ExternalDependency(
138-
"com.github.broadinstitute:picard:3.1.0",
138+
"com.github.broadinstitute:picard:3.4.0",
139139
"Picard Tools Lib",
140140
"PicardTools",
141141
"https://github.com/broadinstitute/picard",

SequenceAnalysis/src/org/labkey/sequenceanalysis/run/util/FastqcRunner.java

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ private List<String> getBaseParams() throws FileNotFoundException
366366
throw new RuntimeException("Not found: " + jbzip2.getPath());
367367
}
368368

369-
File htsjdkJar = new File(libDir, "htsjdk-4.0.0.jar");
369+
File htsjdkJar = findJar(libDir, "htsjdk-");
370370
if (!htsjdkJar.exists())
371371
{
372372
throw new RuntimeException("Not found: " + htsjdkJar.getPath());
@@ -401,6 +401,27 @@ private List<String> getBaseParams() throws FileNotFoundException
401401
return params;
402402
}
403403

404+
private File findJar(final File libDir, final String prefix)
405+
{
406+
if (!libDir.exists())
407+
{
408+
throw new RuntimeException("Missing directory: " + libDir);
409+
}
410+
411+
List<String> jarNames = Arrays.stream(libDir.list()).filter(fn -> fn.startsWith(prefix)).sorted().toList();
412+
if (jarNames.isEmpty())
413+
{
414+
throw new RuntimeException("Unable to find JAR with prefix: " + prefix);
415+
}
416+
417+
if (jarNames.size() > 1)
418+
{
419+
_logger.info("More than one JAR found with prefix: " + prefix);
420+
}
421+
422+
return new File(libDir, jarNames.get(jarNames.size() - 1));
423+
}
424+
404425
private int getThreads()
405426
{
406427
return _threads;

SequenceAnalysis/src/org/labkey/sequenceanalysis/run/variant/KingInferenceStep.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,10 @@ public Output processVariants(File inputVCF, File outputDirectory, ReferenceGeno
115115
plinkArgs.add("--max-alleles");
116116
plinkArgs.add("2");
117117

118+
// NOTE: tools like sawfish can report half-called genotypes, like 0/.. For now, be most conservative in PCA:
119+
plinkArgs.add("--vcf-half-call");
120+
plinkArgs.add("missing");
121+
118122
Integer threads = SequencePipelineService.get().getMaxThreads(getPipelineCtx().getLogger());
119123
if (threads != null)
120124
{

SequenceAnalysis/src/org/labkey/sequenceanalysis/run/variant/PlinkPcaStep.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,6 +227,10 @@ private void runBatch(File inputVCF, File outputDirectory, VariantProcessingStep
227227
args.add(String.valueOf(maxRam));
228228
}
229229

230+
// NOTE: tools like sawfish can report half-called genotypes, like 0/.. For now, be most conservative in PCA:
231+
args.add("--vcf-half-call");
232+
args.add("missing");
233+
230234
args.addAll(getClientCommandArgs());
231235

232236
getWrapper().execute(args);

0 commit comments

Comments
 (0)