-
-
Notifications
You must be signed in to change notification settings - Fork 27
Description
Describe the bug
When attempting to play any song/track in spotatui using native streaming, the following happens:
- Brief moment of normal (or faintly distorted) audio playback at maximum volume (~200% effective, extremely loud).
- Immediately followed by loud, ear-scratching screeching/distortion/noise (like buffer underrun garbage amplified).
- The noise continues for a few seconds until it self-stops.
- spotatui then crashes/exits abruptly (no clean panic message visible in terminal).
- Terminal output (window) is now messed up as the application did not exit handling the escape characters
- Once this happens, it won't make a sound again unless I run
systemctl --user restart pipewire wireplumber pipewire-pulse, but it will still crash if attempted to play a song.
This only occurs on playback initiation (e.g., pressing Enter on a song) or on continue play. The TUI launches and browses fine.
External volume controls (pavucontrol, wpctl, keyboard shortcuts, amixer) have no effect on spotatui's output during the brief playback window, volume appears stuck at hardware-max/full-scale.
To Reproduce
Steps to reproduce the behavior:
- Launch and authenticate
- Select the current device called
spotatui - Attempt to play or continue a song from the terminal/from another device on the device where spotatui is being ran
Expected behavior
- Playback starts normally at a reasonable volume.
- pavucontrol/system volume controls adjust spotatui's output stream.
- No distortion/crash.
Desktop:
- OS: Arch Linux
- Kernel: Linux 6.18.7-arch1-Watanare-T2-1-t2
- Terminal ghostty (with and without tmux)
- Version 0.36.2
Attempts to Fix / Workarounds Tried
- Increased PipeWire quantum/rates in
~/.config/pipewire/pipewire.conf.d/99-audio-fix.conf(1024 quantum, allowed-rates [44100 48000]) - Added WirePlumber rules for soft-mixer / ignore-dB / use-acp in main.lua.d
- Lowered bitrate in spotatui config.yml (not sure if it's supported)
Additional context
Other librespot-based clients like ncspot and spotifyd work perfectly on the same system (normal volume, no crash, controls work). This seems specific to spotatui's integration. I have found some similar issues from the past in librespot and ncspot repositories describing the same issue, but those are solved 5 years ago:
I think my device uses alsa as the backend:
pactl list short sinks
57 alsa_output.pci-0000_02_00.3.Speakers PipeWire s24-32le 4ch 48000Hz SUSPENDED
58 alsa_output.pci-0000_02_00.3.Headphones PipeWire s24-32le 2ch 48000Hz SUSPENDEDAlso, I wasn't able to log the crashes. I couldn't find a way to do it.