From 0d347d662a80a96f3a57a7e5079199b222253af9 Mon Sep 17 00:00:00 2001 From: asivache Date: Thu, 4 Feb 2010 21:06:28 +0000 Subject: [PATCH] More plumbing: if after the shift window contains indel(s) at the first position, do not throw an exception, just print the warning (we can not deal with this situation!!) and discard those indels without trying to call them. This situation will most probably arise after forced shift over a messy region anyway. git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@2781 348d0f76-0448-11de-a6fe-93d51630548a --- .../sting/gatk/walkers/indels/IndelGenotyperV2Walker.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/java/src/org/broadinstitute/sting/gatk/walkers/indels/IndelGenotyperV2Walker.java b/java/src/org/broadinstitute/sting/gatk/walkers/indels/IndelGenotyperV2Walker.java index f4fc9fe19..a2516660d 100644 --- a/java/src/org/broadinstitute/sting/gatk/walkers/indels/IndelGenotyperV2Walker.java +++ b/java/src/org/broadinstitute/sting/gatk/walkers/indels/IndelGenotyperV2Walker.java @@ -1142,8 +1142,11 @@ public class IndelGenotyperV2Walker extends ReadWalker { if ( indels.get(0) != null && indels.get(0).size() != 0 ) { IndelVariant indel = indels.get(0).get(0); - throw new StingException("Indel found at the first position ("+start+") after a shift was performed: currently not supported: "+ - (indel.getType()==IndelVariant.Type.I?"+":"-")+indel.getBases()+"; reads: "+indel.getReadSet().iterator().next().getSAMRecord().getReadName()); + System.out.println("WARNING: Indel(s) at first position in the window ("+refName+":"+start+"): currently not supported: "+ + (indel.getType()==IndelVariant.Type.I?"+":"-")+indel.getBases()+"; read: "+indel.getReadSet().iterator().next().getSAMRecord().getReadName()+"; site ignored"); + indels.get(0).clear(); +// throw new StingException("Indel found at the first position ("+start+") after a shift was performed: currently not supported: "+ +// (indel.getType()==IndelVariant.Type.I?"+":"-")+indel.getBases()+"; reads: "+indel.getReadSet().iterator().next().getSAMRecord().getReadName()); } Iterator read_iter = reads.iterator();