Skip to content

Stream Closed Exception #392

@Z02939

Description

@Z02939

If you play a song 2x in a row, it can be that the cache is not readable. librespot gives an IOException. So the cache is not used and fetches the chunk again from the server?

ERROR CdnManager:313 - Failed requesting chunk from cache, index: 4
java.io.IOException: Stream Closed
at java.io.RandomAccessFile.length(Native Method) ~[?:?]
at xyz.gianlu.librespot.cache.CacheManager$Handler.hasChunk(CacheManager.java:216) ~[librespot-api-1.6.1.jar:1.6.1]
at xyz.gianlu.librespot.audio.cdn.CdnManager$Streamer.requestChunk(CdnManager.java:308) ~[librespot-api-1.6.1.jar:1.6.1]
at xyz.gianlu.librespot.audio.cdn.CdnManager$Streamer.access$1500(CdnManager.java:198) ~[librespot-api-1.6.1.jar:1.6.1]
at xyz.gianlu.librespot.audio.cdn.CdnManager$Streamer$InternalStream.lambda$requestChunkFromStream$0(CdnManager.java:398) ~[librespot-api-1.6.1.jar:1.6.1]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:630) [?:?]
at java.lang.Thread.run(Thread.java:831) [?:?]

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions