[GH-ISSUE #180] Getting "Could not write audio: Invalid argument" although other audio sources work #123

Closed
opened 2026-02-27 19:28:57 +03:00 by kerem · 2 comments
Owner

Originally created by @MarcelKr on GitHub (Mar 3, 2018).
Original GitHub issue: https://github.com/librespot-org/librespot/issues/180

When starting playback, I get the error Could not write audio: Invalid argument. Other audio sources such as mopidy or kodi do work. I use pulseaudio as backend. Below is what I get calling librespot (See this file for the output with -v option)

[marcel@NAS ~]$ librespot --name nas
INFO:librespot: librespot 8e0d758 (2018-02-26). Built on 2018-02-26. Build ID: BFjJS6fG
INFO:librespot_core::session: Connecting to AP "gew1-accesspoint-b-kd8g.ap.spotify.com:4070"
INFO:librespot_core::session: Authenticated as "xxxx" !
INFO:librespot_core::session: Country: "DE"
INFO:librespot_playback::player: Loading track "The Underworld"
INFO:librespot_playback::player: Track "The Underworld" loaded
ERROR:librespot_playback::player: Could not write audio: Invalid argument

SW versions in use:

  • linux kernel 4.15.6
  • pulseaudio 11.1
  • rust 1.24

It's probably me being too stupid to get it running. Any help would be appreciated.

Originally created by @MarcelKr on GitHub (Mar 3, 2018). Original GitHub issue: https://github.com/librespot-org/librespot/issues/180 When starting playback, I get the error ``Could not write audio: Invalid argument``. Other audio sources such as mopidy or kodi do work. I use pulseaudio as backend. Below is what I get calling librespot (See [this file](https://github.com/librespot-org/librespot/files/1777414/output-v.txt) for the output with -v option) ``` [marcel@NAS ~]$ librespot --name nas INFO:librespot: librespot 8e0d758 (2018-02-26). Built on 2018-02-26. Build ID: BFjJS6fG INFO:librespot_core::session: Connecting to AP "gew1-accesspoint-b-kd8g.ap.spotify.com:4070" INFO:librespot_core::session: Authenticated as "xxxx" ! INFO:librespot_core::session: Country: "DE" INFO:librespot_playback::player: Loading track "The Underworld" INFO:librespot_playback::player: Track "The Underworld" loaded ERROR:librespot_playback::player: Could not write audio: Invalid argument ``` SW versions in use: * linux kernel 4.15.6 * pulseaudio 11.1 * rust 1.24 It's probably me being too stupid to get it running. Any help would be appreciated.
kerem closed this issue 2026-02-27 19:28:58 +03:00
Author
Owner

@awiouy commented on GitHub (Mar 3, 2018):

Try disabling option "keep audio sink alive" in Kodi.

<!-- gh-comment-id:370173579 --> @awiouy commented on GitHub (Mar 3, 2018): Try disabling option "keep audio sink alive" in Kodi.
Author
Owner

@MarcelKr commented on GitHub (Mar 4, 2018):

I didn't hear any audio output before since I wasn't in the audio group, arghs. I noticed this by doing pacmd list-sinks, which only showed a dummy output.
So this is a duplicate of #158 now. I have the exact same symptoms.

<!-- gh-comment-id:370238323 --> @MarcelKr commented on GitHub (Mar 4, 2018): I didn't hear any audio output before since I wasn't in the ``audio`` group, arghs. I noticed this by doing ``pacmd list-sinks``, which only showed a dummy output. So this is a duplicate of #158 now. I have the exact same symptoms.
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#123
No description provided.