NPE when validating a CRAM file with a .fasta reference with no .dict file #513

Open
cmnbroad opened this Issue Mar 4, 2016 · 0 comments

Comments

Projects
None yet
1 participant
Contributor

cmnbroad commented Mar 4, 2016

If you pass in a .fasta file for which there is no corresponding .dict file to SamFileValidator you'll get an NPE during NM tag validation. Even though the bug isn't specific to CRAM files, I'm tagging it with the CRAM tag since its way more likely to happen when you're required to pass a reference, as is the case for CRAM files.

java.lang.NullPointerException
at htsjdk.samtools.reference.ReferenceSequenceFileWalker.get(ReferenceSequenceFileWalker.java:87)
at htsjdk.samtools.SamFileValidator.validateNmTag(SamFileValidator.java:462)
at htsjdk.samtools.SamFileValidator.validateSamRecordsAndQualityFormat(SamFileValidator.java:288)
at htsjdk.samtools.SamFileValidator.validateSamFile(SamFileValidator.java:200)
at htsjdk.samtools.SamFileValidator.validateSamFileVerbose(SamFileValidator.java:160)
at org.broadinstitute.hellbender.tools.picard.sam.ValidateSamFile.doWork(ValidateSamFile.java:131)
at org.broadinstitute.hellbender.cmdline.CommandLineProgram.runTool(CommandLineProgram.java:98)
at org.broadinstitute.hellbender.cmdline.CommandLineProgram.instanceMainPostParseArgs(CommandLineProgram.java:146)
at org.broadinstitute.hellbender.cmdline.PicardCommandLineProgram.instanceMain(PicardCommandLineProgram.java:61)
at org.broadinstitute.hellbender.Main.instanceMain(Main.java:66)
at org.broadinstitute.hellbender.Main.instanceMain(Main.java:73)
at org.broadinstitute.hellbender.CommandLineProgramTest.runCommandLine(CommandLineProgramTest.java:72)
at org.broadinstitute.hellbender.tools.picard.sam.ValidateSamFileIntegrationTest.testJunkFile(ValidateSamFileIntegrationTest.java:76)

cmnbroad added the cram label Mar 4, 2016

cmnbroad changed the title from NPE when validating a cram file with a .fasta reference with no .dict file to NPE when validating a CRAM file with a .fasta reference with no .dict file Mar 4, 2016

@SilinPavel SilinPavel added a commit to EpamLifeSciencesTeam/htsjdk that referenced this issue Oct 27, 2016

@SilinPavel SilinPavel resolve issue #513 NPE when validating a CRAM file with a .fasta refe…
…rence with no .dict file
e050366

@ekazachkova ekazachkova added a commit to EpamLifeSciencesTeam/htsjdk that referenced this issue Oct 28, 2016

@SilinPavel @ekazachkova SilinPavel + ekazachkova resolve issue #513 NPE when validating a CRAM file with a .fasta refe…
…rence with no .dict file
34d3b31

@ekazachkova ekazachkova added a commit to EpamLifeSciencesTeam/htsjdk that referenced this issue Oct 28, 2016

@SilinPavel @ekazachkova SilinPavel + ekazachkova resolve issue #513 NPE when validating a CRAM file with a .fasta refe…
…rence with no .dict file
a960c67

@ekazachkova ekazachkova added a commit to EpamLifeSciencesTeam/htsjdk that referenced this issue Oct 28, 2016

@SilinPavel @ekazachkova SilinPavel + ekazachkova resolve issue #513 NPE when validating a CRAM file with a .fasta refe…
…rence with no .dict file
6d3f109

@vadimzalunin vadimzalunin added a commit to vadimzalunin/htsjdk that referenced this issue Feb 17, 2017

@SilinPavel @vadimzalunin SilinPavel + vadimzalunin resolve issue #513 NPE when validating a CRAM file with a .fasta refe…
…rence with no .dict file
9a6f6be

@yfarjoun yfarjoun added a commit that referenced this issue Mar 7, 2017

@ekazachkova @yfarjoun ekazachkova + yfarjoun Fix for issue #513: NPE in ValidateSamFile with CRAM (#735)
* resolve issue #513 NPE when validating a CRAM file with a .fasta reference with no .dict file
6d22658

@magicDGS magicDGS added a commit to magicDGS/htsjdk that referenced this issue Mar 8, 2017

@ekazachkova @magicDGS ekazachkova + magicDGS Fix for issue #513: NPE in ValidateSamFile with CRAM (#735)
* resolve issue #513 NPE when validating a CRAM file with a .fasta reference with no .dict file
78ca562

@vadimzalunin vadimzalunin added a commit to vadimzalunin/htsjdk that referenced this issue Mar 14, 2017

@SilinPavel @vadimzalunin SilinPavel + vadimzalunin resolve issue #513 NPE when validating a CRAM file with a .fasta refe…
…rence with no .dict file
1bc580b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment