htsjdk.samtools.FileTruncatedException: Premature end of file

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via broadinstitute.org by Unknown author, 1 year ago
via broadinstitute.org by Unknown author, 1 year ago
via GitHub by dwaggott
, 2 years ago
Premature end of file
htsjdk.samtools.FileTruncatedException: Premature end of file
at htsjdk.samtools.util.BlockCompressedInputStream.readBlock(BlockCompressedInputStream.java:382)
at htsjdk.samtools.util.BlockCompressedInputStream.available(BlockCompressedInputStream.java:127)
at htsjdk.samtools.util.BlockCompressedInputStream.read(BlockCompressedInputStream.java:252)
at java.io.DataInputStream.read(DataInputStream.java:149)
at htsjdk.samtools.util.BinaryCodec.readBytesOrFewer(BinaryCodec.java:404)
at htsjdk.samtools.util.BinaryCodec.readBytes(BinaryCodec.java:380)
at htsjdk.samtools.util.BinaryCodec.readBytes(BinaryCodec.java:366)
at htsjdk.samtools.BAMRecordCodec.decode(BAMRecordCodec.java:199)
at htsjdk.samtools.BAMFileReader$BAMFileIterator.getNextRecord(BAMFileReader.java:660)
at htsjdk.samtools.BAMFileReader$BAMFileIterator.advance(BAMFileReader.java:634)
at htsjdk.samtools.BAMFileReader$BAMFileIterator.next(BAMFileReader.java:628)
at htsjdk.samtools.BAMFileReader$BAMFileIterator.next(BAMFileReader.java:598)
at htsjdk.samtools.SamReader$AssertingIterator.next(SamReader.java:527)
at htsjdk.samtools.SamReader$AssertingIterator.next(SamReader.java:501)
at htsjdk.samtools.BAMIndexer.createIndex(BAMIndexer.java:287)
at picard.sam.BuildBamIndex.doWork(BuildBamIndex.java:138)
at picard.cmdline.CommandLineProgram.instanceMain(CommandLineProgram.java:187)
at picard.cmdline.PicardCommandLine.instanceMain(PicardCommandLine.java:95)
at picard.cmdline.PicardCommandLine.main(PicardCommandLine.java:105)

Users with the same issue

Samebug visitor profile picture
Unknown user
Once, 1 year ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.