[GH-ISSUE #1322] Unable to load encrypted file: ChannelError #601

Closed
opened 2026-02-27 19:31:31 +03:00 by kerem · 38 comments
Owner

Originally created by @rwjack on GitHub (Sep 2, 2024).
Original GitHub issue: https://github.com/librespot-org/librespot/issues/1322

Describe the bug
All of a sudden I can't play any song

To reproduce
Steps to reproduce the behavior:

  1. Launch librespot with:
stream = spotify:///librespot?name=Spotify&devicename=HA_Snapcast&bitrate=320&volume=100&cache=/data/librespot&cache-size-limit=2G&autoplay=true&params=--disable-discovery
  1. Play any song
  2. Librespot starts skipping songs quickly and crashes within a few seconds.

Log

... SNIP ...
2024-09-02 16-08-33.834 [Info] (librespot_playback::player) Loading <Bliss> with Spotify URI <spotify:track:2wIBOetdiYn4ULg7j4jMg6>
2024-09-02 16-08-33.946 [Error] (librespot_core::channel) channel error: 2 0
2024-09-02 16-08-33.946 [Error] (librespot_playback::player) Unable to load encrypted file: ChannelError
2024-09-02 16-08-33.946 [Warn] (librespot_playback::player) Skipping to next track, unable to load track <SpotifyId { id: 110396896608779253385428011206135924654, audio_type: Track }>: ()
2024-09-02 16-08-33.987 [Info] (librespot_playback::player) Loading <Weightless> with Spotify URI <spotify:track:57bvTWSTYC2HLS3EjmmTgD>
2024-09-02 16-08-34.105 [Error] (librespot_core::channel) channel error: 2 0
2024-09-02 16-08-34.105 [Error] (librespot_playback::player) Unable to load encrypted file: ChannelError
2024-09-02 16-08-34.105 [Warn] (librespot_playback::player) Skipping to next track, unable to load track <SpotifyId { id: 223433050452273652531839940303864379059, audio_type: Track }>: ()
2024-09-02 16-08-34.224 [Info] (librespot_playback::player) Loading <Nara> with Spotify URI <spotify:track:4F8zNOrvP78IJAdrdZCo1z>
2024-09-02 16-08-34.268 [Error] (librespot_core::channel) channel error: 2 0
2024-09-02 16-08-34.268 [Error] (librespot_playback::player) Unable to load encrypted file: ChannelError
2024-09-02 16-08-34.268 [Warn] (librespot_playback::player) Skipping to next track, unable to load track <SpotifyId { id: 203675824406771647439050070553111732737, audio_type: Track }>: ()
2024-09-02 16-08-34.306 [Info] (librespot_playback::player) Loading <Endless Horizon> with Spotify URI <spotify:track:76RFgwdQlwsMi0vfA20gSV>
2024-09-02 16-08-34.432 [Error] (librespot_core::channel) channel error: 2 0
2024-09-02 16-08-34.432 [Error] (librespot_playback::player) Unable to load encrypted file: ChannelError
2024-09-02 16-08-34.432 [Warn] (librespot_playback::player) Skipping to next track, unable to load track <SpotifyId { id: 310556037841223247093127629046494693741, audio_type: Track }>: ()
2024-09-02 16-08-34.432 [Warn] (librespot_connect::spirc) No context to update from!
2024-09-02 16-08-34.544 [Error] (ProcessStream) Error while reading from stderr: End of file
2024-09-02 16-08-34.545 [Error] (AsioStream) Error reading message: End of file, length: 0, ec: asio.misc:2
2024-09-02 16-08-34.646 [Info] (Watchdog) Starting watchdog, timeout: 7800s
2024-09-02 16-08-34.647 [Info] (librespot) librespot 0.4.2 UNKNOWN (Built on 2023-08-01, Build ID: 1690865570, Profile: release)
2024-09-02 16-08-34.691 [Info] (librespot_core::session) Connecting to AP "ap2-gew1.spotify.com:4070"
2024-09-02 16-08-34.767 [Info] (AsioStream) No data since 120 ms, switching to idle
... SNIP ...

Host (what you are running librespot on):

  • OS: Debian container, through Snapcast
  • Platform: HAOS x86
Originally created by @rwjack on GitHub (Sep 2, 2024). Original GitHub issue: https://github.com/librespot-org/librespot/issues/1322 **Describe the bug** All of a sudden I can't play any song **To reproduce** Steps to reproduce the behavior: 1. Launch `librespot` with: ``` stream = spotify:///librespot?name=Spotify&devicename=HA_Snapcast&bitrate=320&volume=100&cache=/data/librespot&cache-size-limit=2G&autoplay=true&params=--disable-discovery ``` 2. Play any song 3. Librespot starts skipping songs quickly and crashes within a few seconds. **Log** ``` ... SNIP ... 2024-09-02 16-08-33.834 [Info] (librespot_playback::player) Loading <Bliss> with Spotify URI <spotify:track:2wIBOetdiYn4ULg7j4jMg6> 2024-09-02 16-08-33.946 [Error] (librespot_core::channel) channel error: 2 0 2024-09-02 16-08-33.946 [Error] (librespot_playback::player) Unable to load encrypted file: ChannelError 2024-09-02 16-08-33.946 [Warn] (librespot_playback::player) Skipping to next track, unable to load track <SpotifyId { id: 110396896608779253385428011206135924654, audio_type: Track }>: () 2024-09-02 16-08-33.987 [Info] (librespot_playback::player) Loading <Weightless> with Spotify URI <spotify:track:57bvTWSTYC2HLS3EjmmTgD> 2024-09-02 16-08-34.105 [Error] (librespot_core::channel) channel error: 2 0 2024-09-02 16-08-34.105 [Error] (librespot_playback::player) Unable to load encrypted file: ChannelError 2024-09-02 16-08-34.105 [Warn] (librespot_playback::player) Skipping to next track, unable to load track <SpotifyId { id: 223433050452273652531839940303864379059, audio_type: Track }>: () 2024-09-02 16-08-34.224 [Info] (librespot_playback::player) Loading <Nara> with Spotify URI <spotify:track:4F8zNOrvP78IJAdrdZCo1z> 2024-09-02 16-08-34.268 [Error] (librespot_core::channel) channel error: 2 0 2024-09-02 16-08-34.268 [Error] (librespot_playback::player) Unable to load encrypted file: ChannelError 2024-09-02 16-08-34.268 [Warn] (librespot_playback::player) Skipping to next track, unable to load track <SpotifyId { id: 203675824406771647439050070553111732737, audio_type: Track }>: () 2024-09-02 16-08-34.306 [Info] (librespot_playback::player) Loading <Endless Horizon> with Spotify URI <spotify:track:76RFgwdQlwsMi0vfA20gSV> 2024-09-02 16-08-34.432 [Error] (librespot_core::channel) channel error: 2 0 2024-09-02 16-08-34.432 [Error] (librespot_playback::player) Unable to load encrypted file: ChannelError 2024-09-02 16-08-34.432 [Warn] (librespot_playback::player) Skipping to next track, unable to load track <SpotifyId { id: 310556037841223247093127629046494693741, audio_type: Track }>: () 2024-09-02 16-08-34.432 [Warn] (librespot_connect::spirc) No context to update from! 2024-09-02 16-08-34.544 [Error] (ProcessStream) Error while reading from stderr: End of file 2024-09-02 16-08-34.545 [Error] (AsioStream) Error reading message: End of file, length: 0, ec: asio.misc:2 2024-09-02 16-08-34.646 [Info] (Watchdog) Starting watchdog, timeout: 7800s 2024-09-02 16-08-34.647 [Info] (librespot) librespot 0.4.2 UNKNOWN (Built on 2023-08-01, Build ID: 1690865570, Profile: release) 2024-09-02 16-08-34.691 [Info] (librespot_core::session) Connecting to AP "ap2-gew1.spotify.com:4070" 2024-09-02 16-08-34.767 [Info] (AsioStream) No data since 120 ms, switching to idle ... SNIP ... ``` **Host (what you are running `librespot` on):** - OS: Debian container, through Snapcast - Platform: HAOS x86
kerem 2026-02-27 19:31:31 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@moretea commented on GitHub (Sep 2, 2024):

Exact same issue here, on nixos-23.11. Will update to latest nixos, to see if it will work.

<!-- gh-comment-id:2325126612 --> @moretea commented on GitHub (Sep 2, 2024): Exact same issue here, on `nixos-23.11`. Will update to latest nixos, to see if it will work.
Author
Owner

@RSKriegs commented on GitHub (Sep 2, 2024):

I've just got the same today via raspotify. Funnily enough it seems to work at some random songs. I'm very confused, seems to be an issue with their backends?

<!-- gh-comment-id:2325127214 --> @RSKriegs commented on GitHub (Sep 2, 2024): I've just got the same today via raspotify. Funnily enough it seems to work at some random songs. I'm very confused, seems to be an issue with their backends?
Author
Owner

@guillaume-duroy commented on GitHub (Sep 2, 2024):

Same here, been working for the past 4 years without a hitch and suddenly all songs are skipped due to a channel error. Setup on rpi4 with raspotify with librespot 0.4.2

<!-- gh-comment-id:2325164344 --> @guillaume-duroy commented on GitHub (Sep 2, 2024): Same here, been working for the past 4 years without a hitch and suddenly all songs are skipped due to a channel error. Setup on rpi4 with raspotify with librespot 0.4.2
Author
Owner

@RSKriegs commented on GitHub (Sep 2, 2024):

Folks I've attempted recompiling and it works when I connected directly to Librespot, do as described here (just compile to release) https://github.com/librespot-org/librespot/blob/dev/COMPILING.md Raspotify still doesn't work, but I can detect Librespot. Don't treat it as a resolution, rather as a workaround.

<!-- gh-comment-id:2325189048 --> @RSKriegs commented on GitHub (Sep 2, 2024): Folks I've attempted recompiling and it works when I connected directly to Librespot, do as described here (just compile to release) https://github.com/librespot-org/librespot/blob/dev/COMPILING.md Raspotify still doesn't work, but I can detect Librespot. Don't treat it as a resolution, rather as a workaround.
Author
Owner

@joeadam commented on GitHub (Sep 2, 2024):

I've got the same issue with librespot 0.4.1 88e64bd

<!-- gh-comment-id:2325291997 --> @joeadam commented on GitHub (Sep 2, 2024): I've got the same issue with librespot 0.4.1 88e64bd
Author
Owner

@b3nis commented on GitHub (Sep 2, 2024):

Same here, with both current and old, unsupported, versions.

<!-- gh-comment-id:2325305590 --> @b3nis commented on GitHub (Sep 2, 2024): Same here, with both current and old, unsupported, versions.
Author
Owner

@kingosticks commented on GitHub (Sep 2, 2024):

There's a workaround at https://github.com/librespot-org/librespot/issues/972#issuecomment-2320943137

<!-- gh-comment-id:2325307761 --> @kingosticks commented on GitHub (Sep 2, 2024): There's a workaround at https://github.com/librespot-org/librespot/issues/972#issuecomment-2320943137
Author
Owner

@rwjack commented on GitHub (Sep 3, 2024):

Am I the only one that's seriously mad for being monkeyed around, having to re-configure a working setup for the 100th time when a simple email to the Librespot dev team and 2 weeks notice would have sufficed.

Let me tell you a little secret, Spotify, truly, does not give a fuck, about it's customers, and let alone the artists.

On the other hand look at us, loyal, paying customers, being fucked over for god knows what time in a row, amazing isn't it.

The main question though, how far are going to let them push this stick up our ass?

How come, there still isn't no decentralized solution for streaming audio, where the artists also get their commission in FULL, no bullshit middleman.

Music is, and always should be by the people, for the people!

<!-- gh-comment-id:2326005035 --> @rwjack commented on GitHub (Sep 3, 2024): Am I the only one that's seriously mad for being monkeyed around, having to re-configure a working setup for the 100th time when a simple email to the Librespot dev team and 2 weeks notice would have sufficed. Let me tell you a little secret, Spotify, truly, does not give a fuck, about it's customers, and let alone the artists. On the other hand look at us, loyal, paying customers, being fucked over for god knows what time in a row, amazing isn't it. The main question though, how far are going to let them push this stick up our ass? How come, there still isn't no decentralized solution for streaming audio, where the artists also get their commission in FULL, no bullshit middleman. Music is, and always should be by the people, for the people!
Author
Owner

@ghost commented on GitHub (Sep 3, 2024):

Same started a couple of days ago.
ERROR librespot_playback::player] Unable to load encrypted file: ChannelError

My solution:
/etc/hosts
0.0.0.0 apresolve.spotify.com
104.199.65.124 ap-gew4.spotify.com

After reading up on this thread I think this might just had been blind luck. Spotify obviously reverted some changes they did. After restoring my hosts file and rebooting, it all started working. Not sure if this fix had any impact. Probably not, I might just have been blind luck that this change and Spotifys reverting was done at the same time.

<!-- gh-comment-id:2326230804 --> @ghost commented on GitHub (Sep 3, 2024): Same started a couple of days ago. ERROR librespot_playback::player] Unable to load encrypted file: ChannelError My solution: /etc/hosts 0.0.0.0 apresolve.spotify.com 104.199.65.124 ap-gew4.spotify.com After reading up on this thread I think this might just had been blind luck. Spotify obviously reverted some changes they did. After restoring my hosts file and rebooting, it all started working. Not sure if this fix had any impact. Probably not, I might just have been blind luck that this change and Spotifys reverting was done at the same time.
Author
Owner

@sowthistle commented on GitHub (Sep 3, 2024):

@LiD420

My solution: /etc/hosts 0.0.0.0 apresolve.spotify.com 104.199.65.124 ap-gew4.spotify.com

Umm. Any chance of a brief explanation of what this does and why it solves the problem? (BTW, as may be obvious from my request, I know nothing about librespot.)

<!-- gh-comment-id:2326586092 --> @sowthistle commented on GitHub (Sep 3, 2024): @LiD420 > My solution: /etc/hosts 0.0.0.0 apresolve.spotify.com 104.199.65.124 ap-gew4.spotify.com Umm. Any chance of a brief explanation of what this does and why it solves the problem? (BTW, as may be obvious from my request, I know nothing about librespot.)
Author
Owner

@OK9UWU commented on GitHub (Sep 3, 2024):

Hello guys.
Suffering from the same issue as y'all do, tried to add the DNS records but to no avail, the error stands solid.
Using librespot on libreelec and armbian. :/

<!-- gh-comment-id:2326855432 --> @OK9UWU commented on GitHub (Sep 3, 2024): Hello guys. Suffering from the same issue as y'all do, tried to add the DNS records but to no avail, the error stands solid. Using librespot on libreelec and armbian. :/
Author
Owner

@codydubat commented on GitHub (Sep 3, 2024):

Having the same issue on raspotify for 2 days already. Yesterday I managed to get it working by setting apresolve.spotify.com to 0.0.0.0, but today nothing seems to be working anymore, not even setting the host for individual APs.

<!-- gh-comment-id:2326886060 --> @codydubat commented on GitHub (Sep 3, 2024): Having the same issue on raspotify for 2 days already. Yesterday I managed to get it working by setting apresolve.spotify.com to 0.0.0.0, but today nothing seems to be working anymore, not even setting the host for individual APs.
Author
Owner

@kingosticks commented on GitHub (Sep 3, 2024):

There's a pre-existing related issue at https://github.com/librespot-org/librespot/issues/972#issuecomment-2320943137. We need to close one of these. But I'll repeat it here, the workaround is dead already, you need to use the latest code from the dev branch where the issue is not present.

<!-- gh-comment-id:2326893786 --> @kingosticks commented on GitHub (Sep 3, 2024): There's a pre-existing related issue at https://github.com/librespot-org/librespot/issues/972#issuecomment-2320943137. We need to close one of these. But I'll repeat it here, the workaround is dead already, you need to use the latest code from the dev branch where the issue is not present.
Author
Owner

@bitclick commented on GitHub (Sep 3, 2024):

use the latest code from the dev branch where the issue is not present

i can confirm:

  • compiled on my desktop following the guide in the documentation.
  • built with cargo build --release --no-default-features --features alsa-backend (i use the pipe-backend to snapcast)
  • tested on desktop - worked immediately
  • copied the binary to another host (soundserver, same architecture) - works as drop-in for the old version (0.4.2 i think)
<!-- gh-comment-id:2327209925 --> @bitclick commented on GitHub (Sep 3, 2024): > use the latest code from the dev branch where the issue is not present i can confirm: - compiled on my desktop following the guide in the documentation. - built with `cargo build --release --no-default-features --features alsa-backend` (i use the pipe-backend to snapcast) - tested on desktop - worked immediately - copied the binary to another host (soundserver, same architecture) - works as drop-in for the old version (`0.4.2` i think)
Author
Owner

@RSKriegs commented on GitHub (Sep 3, 2024):

Adhering to all of the comments related to compiling the dev branch, I'll add that you can also set up Librespot as a service so it runs on startup:
https://github.com/librespot-org/librespot/wiki/Running-as-a-service
Works on Raspbian for me. I run it as an user service. If you compile this & point the compiled file in ExecStart parameter in librespot.service (or whatever you name it) file you should succeed. Basically everything is in Librespot's documentation :) Hope I've saved someone's time and that it will work consistently.

<!-- gh-comment-id:2327253250 --> @RSKriegs commented on GitHub (Sep 3, 2024): Adhering to all of the comments related to compiling the dev branch, I'll add that you can also set up Librespot as a service so it runs on startup: https://github.com/librespot-org/librespot/wiki/Running-as-a-service Works on Raspbian for me. I run it as an user service. If you compile this & point the compiled file in ExecStart parameter in librespot.service (or whatever you name it) file you should succeed. Basically everything is in Librespot's documentation :) Hope I've saved someone's time and that it will work consistently.
Author
Owner

@MattGesicki commented on GitHub (Sep 3, 2024):

use the latest code from the dev branch where the issue is not present

i can confirm:

* compiled on my desktop following the guide in the documentation.

* built with `cargo build --release --no-default-features --features alsa-backend`    (i use the pipe-backend to snapcast)

* tested on desktop - worked immediately

* copied the binary to another host (soundserver, same architecture)  - works as drop-in for the old version (`0.4.2` i think)

Hi bitclick,
Thank you for the solution, I experienced the same problem.
Could you please provide me and other 'mortals' a quick guide how to implement a fix?
Where I can find latest dev branch and documentation to follow?
Thanks in advance!

<!-- gh-comment-id:2327259860 --> @MattGesicki commented on GitHub (Sep 3, 2024): > > use the latest code from the dev branch where the issue is not present > > i can confirm: > > * compiled on my desktop following the guide in the documentation. > > * built with `cargo build --release --no-default-features --features alsa-backend` (i use the pipe-backend to snapcast) > > * tested on desktop - worked immediately > > * copied the binary to another host (soundserver, same architecture) - works as drop-in for the old version (`0.4.2` i think) Hi bitclick, Thank you for the solution, I experienced the same problem. Could you please provide me and other 'mortals' a quick guide how to implement a fix? Where I can find latest dev branch and documentation to follow? Thanks in advance!
Author
Owner

@RSKriegs commented on GitHub (Sep 3, 2024):

@MattGesicki follow the steps just like here https://github.com/librespot-org/librespot/blob/dev/COMPILING.md
If you want to add it as a service so it boots on a startup do the following: https://github.com/librespot-org/librespot/wiki/Running-as-a-service

Note that compilation may take some time. Also compile a release build instead of debug.

<!-- gh-comment-id:2327265285 --> @RSKriegs commented on GitHub (Sep 3, 2024): @MattGesicki follow the steps just like here https://github.com/librespot-org/librespot/blob/dev/COMPILING.md If you want to add it as a service so it boots on a startup do the following: https://github.com/librespot-org/librespot/wiki/Running-as-a-service Note that compilation may take some time. Also compile a release build instead of debug.
Author
Owner

@MattGesicki commented on GitHub (Sep 3, 2024):

@RSKriegs thanks!
I learned a few things today which are obvious for you :)
I've installed rust and C compiler, added ssh publickey, forked librespot and downloaded it.
One last thing before trying to compile - I'm not sure what audio backend I have. Do they mean a hardware device I use in RaspberryPi?

<!-- gh-comment-id:2327356722 --> @MattGesicki commented on GitHub (Sep 3, 2024): @RSKriegs thanks! I learned a few things today which are obvious for you :) I've installed rust and C compiler, added ssh publickey, forked librespot and downloaded it. One last thing before trying to compile - I'm not sure what audio backend I have. Do they mean a hardware device I use in RaspberryPi?
Author
Owner

@RSKriegs commented on GitHub (Sep 3, 2024):

@MattGesicki I didn't dive into that, I used the default one and it's ok. No it's not a hardware device.

However, raw Librespot doesn't work 100% as well as Raspotify for me yet and there are minor issues, but at least it runs. (Most likely some additional setup considerations)

<!-- gh-comment-id:2327382952 --> @RSKriegs commented on GitHub (Sep 3, 2024): @MattGesicki I didn't dive into that, I used the default one and it's ok. No it's not a hardware device. However, raw Librespot doesn't work 100% as well as Raspotify for me yet and there are minor issues, but at least it runs. (Most likely some additional setup considerations)
Author
Owner

@fnndyl commented on GitHub (Sep 3, 2024):

Compiling from dev does seem to have fixed the issue for me :)

<!-- gh-comment-id:2327407554 --> @fnndyl commented on GitHub (Sep 3, 2024): Compiling from dev does seem to have fixed the issue for me :)
Author
Owner

@kosmo2k commented on GitHub (Sep 3, 2024):

Compiled from the dev branch on a raspberry pi, worked for me. Use it with Snapcast, no issues so far :)

<!-- gh-comment-id:2327474833 --> @kosmo2k commented on GitHub (Sep 3, 2024): Compiled from the dev branch on a raspberry pi, worked for me. Use it with Snapcast, no issues so far :)
Author
Owner

@lpicanco commented on GitHub (Sep 3, 2024):

Having the same issue on moode. I will compile the dev branch and test with it.

[2024-09-03T22:13:50Z WARN  librespot_core::apresolve] Using fallback "ap.spotify.com:443"
[2024-09-03T22:13:50Z INFO  librespot_core::session] Connecting to AP "ap.spotify.com:443"
...
[2024-09-03T22:24:11Z ERROR librespot_core::channel] channel error: 2 0
[2024-09-03T22:24:11Z ERROR librespot_playback::player] Unable to load encrypted file: ChannelError
[2024-09-03T22:24:11Z WARN  librespot_playback::player] Skipping to next track, unable to load track <SpotifyId { id: 3014....., audio_type: Track }>: ()
[2024-09-03T22:24:11Z DEBUG librespot_connect::spirc] At track 10 of 11 <"spotify:playlist:37i9...."> update [true]
[2024-09-03T22:24:11Z TRACE librespot_connect::spirc] Sending status to server: [kPlayStatusPlay]

Edit: It is working now after applying these changes: https://github.com/librespot-org/librespot/issues/1322#issuecomment-2328404268

<!-- gh-comment-id:2327548621 --> @lpicanco commented on GitHub (Sep 3, 2024): Having the same issue on moode. I will compile the dev branch and test with it. ```txt [2024-09-03T22:13:50Z WARN librespot_core::apresolve] Using fallback "ap.spotify.com:443" [2024-09-03T22:13:50Z INFO librespot_core::session] Connecting to AP "ap.spotify.com:443" ... [2024-09-03T22:24:11Z ERROR librespot_core::channel] channel error: 2 0 [2024-09-03T22:24:11Z ERROR librespot_playback::player] Unable to load encrypted file: ChannelError [2024-09-03T22:24:11Z WARN librespot_playback::player] Skipping to next track, unable to load track <SpotifyId { id: 3014....., audio_type: Track }>: () [2024-09-03T22:24:11Z DEBUG librespot_connect::spirc] At track 10 of 11 <"spotify:playlist:37i9...."> update [true] [2024-09-03T22:24:11Z TRACE librespot_connect::spirc] Sending status to server: [kPlayStatusPlay] ``` Edit: It is working now after applying these changes: https://github.com/librespot-org/librespot/issues/1322#issuecomment-2328404268
Author
Owner

@Semmu commented on GitHub (Sep 3, 2024):

im running spotifyd 0.3.5 and this issue started happening today for me too, basically my spotify client is completely broken now.

(gotta love it when spotify breaks our clients on their end...)

<!-- gh-comment-id:2327647787 --> @Semmu commented on GitHub (Sep 3, 2024): im running spotifyd 0.3.5 and this issue started happening today for me too, basically my spotify client is completely broken now. (gotta love it when spotify breaks our clients on their end...)
Author
Owner

@User65k commented on GitHub (Sep 4, 2024):

Can confirm,

  1. dev branch is working (for Spotify connect)
    cargo install --git https://github.com/librespot-org/librespot.git --branch dev --no-default-features --features alsa-backend.
  2. /etc/hosts changes dont help
  3. login gives bad credentials. There is another Issue for it
<!-- gh-comment-id:2328160807 --> @User65k commented on GitHub (Sep 4, 2024): Can confirm, 1. dev branch is working (for Spotify connect) `cargo install --git https://github.com/librespot-org/librespot.git --branch dev --no-default-features --features alsa-backend`. 2. `/etc/hosts` changes dont help 3. login gives bad credentials. There is another Issue for it
Author
Owner

@thomasbuesser commented on GitHub (Sep 4, 2024):

login is still not working here...

<!-- gh-comment-id:2328174014 --> @thomasbuesser commented on GitHub (Sep 4, 2024): login is still not working here...
Author
Owner

@LosTigeros commented on GitHub (Sep 4, 2024):

Got it working again in moode player.

  1. Create a release build from the dev branch following this, and to build, use this command:
    cargo build --release --no-default-features --features alsa-backend
  2. Backup old & copy new built librespot to the /usr/bin/:
    sudo mv /usr/bin/librespot /usr/bin/librespot.old && sudo cp target/release/librespot /usr/bin/librespot
  3. Go to the moode renderers -> Spotify connect settings and make sure the Autoplay is set to No, otherwise librespot will just error and stop.
  4. Disable the ap-port parameter, otherwise it won't be able to resolve all access points:
    sudo nano /var/www/inc/renderer.php - line 110
    Change ' --ap-port 13561 ' to empty '', or comment it out like this: ''; //' --ap-port 13561 ' so you can restore it once there is a proper fix.
    image
    Save the changes (CTRL+O and then CTRL+X)
  5. Reboot the device:
    sudo reboot

If you made any changes to the /etc/hosts file like recommended above, please remove those entries before rebooting.

<!-- gh-comment-id:2328404268 --> @LosTigeros commented on GitHub (Sep 4, 2024): Got it working again in moode player. 1. Create a release build from the `dev` branch following [this](https://github.com/librespot-org/librespot/blob/dev/COMPILING.md), and to build, use this command: `cargo build --release --no-default-features --features alsa-backend` 2. Backup old & copy new built `librespot` to the `/usr/bin/`: `sudo mv /usr/bin/librespot /usr/bin/librespot.old && sudo cp target/release/librespot /usr/bin/librespot` 3. Go to the moode renderers -> Spotify connect settings and make sure the `Autoplay` is set to `No`, otherwise `librespot` will just error and stop. 4. Disable the `ap-port` parameter, otherwise it won't be able to resolve all access points: `sudo nano /var/www/inc/renderer.php` - line 110 Change `' --ap-port 13561 '` to empty `''`, or comment it out like this: `''; //' --ap-port 13561 '` so you can restore it once there is a proper fix. ![image](https://github.com/user-attachments/assets/8c479cc8-ac85-4e1e-8c89-7f6006793009) Save the changes (CTRL+O and then CTRL+X) 5. Reboot the device: `sudo reboot` If you made any changes to the `/etc/hosts` file like recommended above, please remove those entries before rebooting.
Author
Owner

@arthurus commented on GitHub (Sep 4, 2024):

Can anyone identify which commit from the dev branch fixes this? It might be possible to backport it to other versions. It's not possible for me to just start using dev now because I have a customized fork for an old MIPS router and the newer versions won't work there.

<!-- gh-comment-id:2328413051 --> @arthurus commented on GitHub (Sep 4, 2024): Can anyone identify which commit from the dev branch fixes this? It might be possible to backport it to other versions. It's not possible for me to just start using dev now because I have a customized fork for an old MIPS router and the newer versions won't work there.
Author
Owner

@dspearson commented on GitHub (Sep 4, 2024):

Can anyone identify which commit from the dev branch fixes this? It might be possible to backport it to other versions. It's not possible for me to just start using dev now because I have a customized fork for an old MIPS router and the newer versions won't work there.

I hit the issue too and confirm that it is fixed at the tip. I'll try and do a git bisect when I have some time (probably sometime in the next few days) to try and identify the change, since I could not see anything obvious in the commit logs or pull requests that is related. Or maybe one of the devs can chime in if they already know specifically.

Might be worth someone tagging a new release given the latest tag doesn't work for a lot of people.

<!-- gh-comment-id:2329685789 --> @dspearson commented on GitHub (Sep 4, 2024): > Can anyone identify which commit from the dev branch fixes this? It might be possible to backport it to other versions. It's not possible for me to just start using dev now because I have a customized fork for an old MIPS router and the newer versions won't work there. I hit the issue too and confirm that it is fixed at the tip. I'll try and do a git bisect when I have some time (probably sometime in the next few days) to try and identify the change, since I could not see anything obvious in the commit logs or pull requests that is related. Or maybe one of the devs can chime in if they already know specifically. Might be worth someone tagging a new release given the latest tag doesn't work for a lot of people.
Author
Owner

@kingosticks commented on GitHub (Sep 4, 2024):

0.4 (master) and 0.5 (dev) use entirely different methods to retrive the audio data. Spotify probably just disabled the old method used in 0.4, just as they disabled user+password auth. It's very different, it's not going to be a simple change to backport. Everyone will need to move to 0.5 (dev) and there will hopefully be a release of that soon, but a lack of release shouldn't be stopping anyone.

<!-- gh-comment-id:2329702406 --> @kingosticks commented on GitHub (Sep 4, 2024): 0.4 (master) and 0.5 (dev) use [entirely different methods](https://github.com/librespot-org/librespot/pull/891) to retrive the audio data. Spotify probably just disabled the old method used in 0.4, just as they disabled user+password auth. It's very different, it's not going to be a simple change to backport. Everyone will need to move to 0.5 (dev) and there will hopefully be a release of that soon, but a lack of release shouldn't be stopping anyone.
Author
Owner

@whisperzer0 commented on GitHub (Sep 4, 2024):

Can confirm the steps outlined in:

https://github.com/librespot-org/librespot/issues/1322#issuecomment-2328160807

cargo install --git https://github.com/librespot-org/librespot.git --branch dev --no-default-features --features alsa-backend

Works for me. - 5th Sept 2024

<!-- gh-comment-id:2330334126 --> @whisperzer0 commented on GitHub (Sep 4, 2024): Can confirm the steps outlined in: https://github.com/librespot-org/librespot/issues/1322#issuecomment-2328160807 > cargo install --git https://github.com/librespot-org/librespot.git --branch dev --no-default-features --features alsa-backend Works for me. - 5th Sept 2024
Author
Owner

@dflvunoooooo commented on GitHub (Sep 5, 2024):

Can confirm the steps outlined in:

#1322 (comment)

cargo install --git https://github.com/librespot-org/librespot.git --branch dev --no-default-features --features alsa-backend

Works for me. - 5th Sept 2024

I can confirm this is working. Connection is slow though. And I get the error

ContextError: Error { kind: InvalidArgument, error: StatusCode(400) }

But despite that it is working.

<!-- gh-comment-id:2331103629 --> @dflvunoooooo commented on GitHub (Sep 5, 2024): > Can confirm the steps outlined in: > > [#1322 (comment)](https://github.com/librespot-org/librespot/issues/1322#issuecomment-2328160807) > > > cargo install --git https://github.com/librespot-org/librespot.git --branch dev --no-default-features --features alsa-backend > > Works for me. - 5th Sept 2024 I can confirm this is working. Connection is slow though. And I get the error ``` ContextError: Error { kind: InvalidArgument, error: StatusCode(400) } ``` But despite that it is working.
Author
Owner

@ejurgensen commented on GitHub (Sep 6, 2024):

Spotify seems to have rolled back the breaking change. Since they didn't announce the change, and since the old protocol only broke partially (just chunk requests?), maybe the change wasn't intentional in the first place.

<!-- gh-comment-id:2334271629 --> @ejurgensen commented on GitHub (Sep 6, 2024): Spotify seems to have rolled back the breaking change. Since they didn't announce the change, and since the old protocol only broke partially (just chunk requests?), maybe the change wasn't intentional in the first place.
Author
Owner

@kingosticks commented on GitHub (Sep 6, 2024):

My guess it's all related to https://github.com/librespot-org/librespot/discussions/1288

This is exactly what happened when they started deprecating libspotify. Seems they didn't learn much from that mess.

<!-- gh-comment-id:2334773058 --> @kingosticks commented on GitHub (Sep 6, 2024): My guess it's all related to https://github.com/librespot-org/librespot/discussions/1288 This is exactly what happened when they started deprecating libspotify. Seems they didn't learn much from that mess.
Author
Owner

@roderickvd commented on GitHub (Sep 7, 2024):

Probably. I suspect that when it was broken for us, it was broken on all official legacy devices out there.

Still, enough reason to start releasing 0.5.

<!-- gh-comment-id:2335043306 --> @roderickvd commented on GitHub (Sep 7, 2024): Probably. I suspect that when it was broken for us, it was broken on all official legacy devices out there. Still, enough reason to start releasing 0.5.
Author
Owner

@rwjack commented on GitHub (Sep 23, 2024):

FYI I'm not getting these errors anymore, with or without the /etc/hosts change. Although I am still having troubles with 1340 ^

<!-- gh-comment-id:2367925685 --> @rwjack commented on GitHub (Sep 23, 2024): FYI I'm not getting these errors anymore, with or without the /etc/hosts change. Although I am still having troubles with 1340 ^
Author
Owner

@kingosticks commented on GitHub (Sep 23, 2024):

Are you able to reproduce this issue with the very latest (today's) dev branch code? If so, please provide full debug log showing it occurring.

<!-- gh-comment-id:2369199997 --> @kingosticks commented on GitHub (Sep 23, 2024): Are you able to reproduce this issue with the very latest (today's) dev branch code? If so, please provide full debug log showing it occurring.
Author
Owner

@rwjack commented on GitHub (Sep 23, 2024):

@kingosticks How can I test it out?

This is how I get 0.4.2: github.com/rwjack/addon-snapserver-spotify@f887f5eba6/snapserver/Dockerfile (L18)

Is it possible for you guys to get an RC out for testing?

<!-- gh-comment-id:2369225054 --> @rwjack commented on GitHub (Sep 23, 2024): @kingosticks How can I test it out? This is how I get 0.4.2: https://github.com/rwjack/addon-snapserver-spotify/blob/f887f5eba609024cb12993393fb0143241c71837/snapserver/Dockerfile#L18 Is it possible for you guys to get an RC out for testing?
Author
Owner

@rwjack commented on GitHub (Sep 29, 2024):

More info about my failed builds on: https://github.com/librespot-org/librespot/issues/1346

We need that RC out, getting this thing compiled is bullshit.

<!-- gh-comment-id:2381267075 --> @rwjack commented on GitHub (Sep 29, 2024): More info about my failed builds on: https://github.com/librespot-org/librespot/issues/1346 We need that RC out, getting this thing compiled is bullshit.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/librespot#601
No description provided.