Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spotify-qt passes invalid argument to librespot 0.5.0 #217

Closed
riiga opened this issue May 16, 2023 · 0 comments
Closed

Spotify-qt passes invalid argument to librespot 0.5.0 #217

riiga opened this issue May 16, 2023 · 0 comments

Comments

@riiga
Copy link
Contributor

riiga commented May 16, 2023

System information

ABI             : x86_64-little_endian-lp64
App version     : v3.10
Build type      : Release
Current desktop : KDE
D-Bus support   : Yes
Install type    : System
KCrash support  : Yes
Kernel          : linux 6.1.25-1-MANJARO
Keychain support: Yes
Platform        : xcb
Product         : Manjaro Linux
Qt version      : 5.15.8

Detailed information

In 7694741 support was added for librespot 0.5.0 as discussed in #210, however while trying to start librespot through spotify-qt it fails saying [err] Error parsing command line options: Argument to option 'autoplay' missing

It would seem 0.5.0 does support autoplay, but the syntax for autoplay has changed and with the current check in the code spotify-qt can't tell 0.4.2 and earlier versions from 0.5.0 and later.

I've downloaded the code and tried locally building it with a quick hack, changing the last line of supportsAutoplay in helper.cpp to return help.contains(QStringLiteral("--autoplay")) && !help.contains(QStringLiteral("--autoplay OVERRIDE")); which solves the problem.

A more ideal solution would probably be to support both versions by checking the version as the helper function itself already expects librespot for any true value. Depending on version, the arguments passed to librespot could be adjusted accordingly.

What happens?

librespot fails to start, so spotify-qt is unable to play any music.

What should happen?

librespot should start so I can play music.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants