java.io.IOException

Premature EOF

Samebug tips1

When you iterate over the lines of a scala.io.Source with source.getLines, make sure you do not close the source until you processed the iterator.

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.

Solutions on the web526

  • via Apache Bugzilla by Shivanshshah.shah94, 1 year ago
    Premature EOF
  • via Google Groups by Kartik Vijaywargi, 5 months ago
    Premature EOF
  • via Google Groups by sele...@googlecode.com, 1 year ago
    Premature EOF
  • Stack trace

    • java.io.IOException: Premature EOF at sun.net.www.http.ChunkedInputStream.readAheadBlocking(ChunkedInputStream.java:565) at sun.net.www.http.ChunkedInputStream.readAhead(ChunkedInputStream.java:609) at sun.net.www.http.ChunkedInputStream.read(ChunkedInputStream.java:696) at java.io.FilterInputStream.read(FilterInputStream.java:133) at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(HttpURLConnection.java:3066) at java.io.BufferedInputStream.read1(BufferedInputStream.java:273) at java.io.BufferedInputStream.read(BufferedInputStream.java:334) at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:283) at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:325) at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:177) at java.io.InputStreamReader.read(InputStreamReader.java:184) at java.io.BufferedReader.fill(BufferedReader.java:154) at java.io.BufferedReader.readLine(BufferedReader.java:317) at java.io.BufferedReader.readLine(BufferedReader.java:382) at au.com.bytecode.opencsv.CSVReader.getNextLine(CSVReader.java:266) at au.com.bytecode.opencsv.CSVReader.readNext(CSVReader.java:233) at au.org.ala.biocache.tool.Sampling.processBatchRemote(Sampling.scala:491) at au.org.ala.biocache.tool.Sampling.sampling(Sampling.scala:368) at au.org.ala.biocache.tool.Sampling$.main(Sampling.scala:115) at au.org.ala.biocache.cmd.CMD2$.main(CMD2.scala:134) at au.org.ala.biocache.cmd.CMD2.main(CMD2.scala)

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    Once, 2 weeks ago
    Once, 1 month ago
    Once, 2 months ago
    22 times, 5 months ago
    Once, 6 months ago
    19 more bugmates