FS#77008 - [ncspot] runtime dependency on pulseaudio-alsa

Attached to Project: Community Packages
Opened by Francesco Minnocci (BachoSeven) - Wednesday, 04 January 2023, 20:52 GMT
Last edited by Toolybird (Toolybird) - Sunday, 08 January 2023, 01:04 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Konstantin Gizdov (kgizdov)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

After switching from the AUR package to the [community] one, I get the following runtime error unless I install `pulseaudio-alsa`:

$ ncspot
Connecting to Spotify..
ALSA lib pcm_dmix.c:999:(snd_pcm_dmix_open) unable to open slave

Additional info:
* version: 0.12.0-4
This task depends upon

Closed by  Toolybird (Toolybird)
Sunday, 08 January 2023, 01:04 GMT
Reason for closing:  Fixed
Additional comments about closing:  ncspot 0.12.0-5
Comment by Toolybird (Toolybird) - Thursday, 05 January 2023, 03:26 GMT
Cannot repro in a fresh VM. It launches to the login screen at least. What happens if you try with a fresh user account...or backup and delete the config?
Comment by Francesco Minnocci (BachoSeven) - Thursday, 05 January 2023, 12:00 GMT
Removing the config completely yields the same result; removing the cached login credentials indeed gets me to the login screen but once I'm logged in it gives the same error.

The backtrace from `.cache/ncspot` is the following:


0: <unknown>
1: <unknown>
2: <unknown>
3: <unknown>
4: <unknown>
5: <unknown>
6: <unknown>
7: <unknown>
8: <unknown>
9: <unknown>
10: <unknown>
11: <unknown>
12: <unknown>

panicked at 'called `Result::unwrap()` on an `Err` value: StreamError(DefaultStreamConfigError(DeviceNotAvailable))', /build/.cargo/registry/src/github.com-1ecc6299db9ec823/librespot-playback-0.4.2/src/audio_backend/rodio.rs:178:53


I attach the log obtained using the `--debug` flag.
Comment by Francesco Minnocci (BachoSeven) - Thursday, 05 January 2023, 12:11 GMT
It has clearly got something to do with the audio backend defaulting to Rodio for some reason; perhaps we shouldn't compile with `--all-features` as the alternative audio backends (PortAudio, Rodio) are intended for use with Windows/MacOS/BSD (see https://github.com/hrkfdn/ncspot/#audio-backends).

Perhaps it would be best to compile without portaudio and rodio dependencies, as Linux users shouldn't need them. It seems to me like a superflous dependency
Comment by Konstantin Gizdov (kgizdov) - Friday, 06 January 2023, 02:12 GMT
Could you try ncspot 0.12.0-5? Let me know how it goes.
Comment by Francesco Minnocci (BachoSeven) - Friday, 06 January 2023, 23:10 GMT
It works as intended now, thanks!

Loading...