feat: Qobuz auth-token (user_id + token) login as a reliable alternative to email/password

Qobuz's email/password API login returns 401 even with valid credentials
(a known Qobuz limitation, unaffected by streamrip version). Add settings
fields for a Qobuz user ID + auth token (token stored encrypted); when both
are present StreamripClient uses use_auth_token=True, else falls back to
email/password.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Jonathan
2026-07-11 00:46:17 +02:00
parent caa0d542ea
commit 00b3dddca6
5 changed files with 73 additions and 11 deletions
+7
View File
@@ -11,5 +11,12 @@ def test_hashed_password_is_md5_hex():
def test_is_configured():
# email + password
assert StreamripClient({"qobuz.email": "a@b.c", "qobuz.password": "p"}).is_configured() is True
# user_id + auth token (the reliable path)
assert StreamripClient({"qobuz.user_id": "123", "qobuz.auth_token": "tok"}).is_configured() is True
# nothing configured
assert StreamripClient({}).is_configured() is False
# partial (token without user_id, password without email) -> not configured
assert StreamripClient({"qobuz.auth_token": "tok"}).is_configured() is False
assert StreamripClient({"qobuz.password": "p"}).is_configured() is False