- Add a form to create a cluster mix rule: shown on first visit when there
are no rules, and from a + in the sidebar for another Listenbrainz user.
Backed by POST /api/discover/rules, which validates each setting and
allows one rule per Listenbrainz user.
- Add deleting a user's mixes from a bin in the sidebar, optionally also
deleting the mixes' playlists from Subsonic. Backed by
DELETE /api/discover/rules/<id>?delete_playlists=true.
- Stop showing the previous user's mix while a new user's mixes build.
- Remove the per-account Listenbrainz token: LB Radio now always uses
listenbrainz.token from the config. A migration drops the token columns
from app_user, and PUT /api/auth/account/listenbrainz is gone.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The first visit to the UI creates the account from a username and password;
after that every API route needs a session cookie from logging in. Accounts
are stored in app_user (Argon2id password hashes) and sessions in
user_session (SHA-256 token hashes, 30 days).
The account page lets the user save a Listenbrainz token, checked with
Listenbrainz first. It takes priority over listenbrainz.token from the
config for LB Radio suggestions.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Package discover/dist to /usr/share/playlistd/discover, and serve it
from there in the default config. cargo deb refuses to package if the
UI hasn't been built, rather than shipping without it.
- Install a pinned Node.js (22.23.4, checksum-verified) in the
Containerfile; Ubuntu 22.04's is too old for Vite. The README's build
command now builds the UI first.
- Recommend yt-dlp, for playing suggested songs from YouTube.
- If discover.ui points to a missing directory, warn instead of letting
Rocket panic at startup.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018opPJMJjLWr4RqdG6vuK6p
Rocket's logger was the only one, so messages from the daemons depended on
it having launched, and most messages bypassed logging with println!.
- Install env_logger at startup: level from log.level (LOG_LEVEL), with
RUST_LOG overriding it. Rocket's per-request logs and sqlx's Postgres
notices are kept to warnings.
- Under systemd, prefix lines with their syslog priority so journald
records levels (journalctl -p warning works).
- Replace every println! with a log macro at a fitting level.
- Recurring failures are a warning when they start or change, debug while
they repeat, and an info message when they recover.
- Listenbrainz errors are readable: an unknown user is "Listenbrainz user
"x" doesn't exist" rather than a JSON decode error, and a period without
stats yet (204) leaves the playlist alone instead of failing to decode.
The UI's Refresh shows the same messages.
- Warnings name the playlist or rule they're about.
- Songs missing from the library are debug output, not errors every tick.
- Daemons no longer run twice at startup (interval's first tick is
immediate), and a failing playlist rule or daemon is logged instead of
panicking the task.
- Subsonic errors display as messages rather than Debug output.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018opPJMJjLWr4RqdG6vuK6p
Each mix rebuild now also finds songs that aren't in the library: the
user's Listenbrainz recommendations they've never played, plus an LB
Radio prompt per mix when a Listenbrainz token is configured. Each
candidate goes to the mix whose genre profile it fits best and is
skipped if it's already in the library or was played recently.
discover/ is a new React app to listen to the mixes: library songs
stream from Subsonic and suggested songs are found on YouTube with
yt-dlp, both proxied through playlistd with Range support for seeking.
Suggestions can be liked (kept in a "Liked new songs" list) or hidden.
- discover: candidate gathering, genre fit scoring, library filtering
- web: /api/discover routes, Subsonic/YouTube streaming proxy
- youtube: yt-dlp search (skipping hour-long results) and audio URLs
- mix tags now hold library genre names, for display in the UI
- config: listenbrainz.token, discover.ui, discover.ytdlp, discover.format
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018opPJMJjLWr4RqdG6vuK6p