Sixteen handlers answered a missing caller with error 50 "Not
authenticated"; the star, unstar and scrobble handlers answered error 0
"Unauthenticated". Middleware stops such a request first, so no app saw
it, but the next handler copied would pick one at random. requireUser
now holds the check, the same shape as /api's, at all 21 sites.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The last Subsonic methods apps call that Minstrel didn't answer:
- getScanStatus counts the songs whose files are present and says
whether a scan is running; startScan, for an admin, starts the scan the
web app's Rescan starts, and answers "scanning" straight away since the
scan records itself a moment later.
- getArtistInfo and getArtistInfo2 give the artist's MusicBrainz id and the
artists in this library that sound like them, from an artist, album or
song id; getAlbumInfo and getAlbumInfo2 give the album's MusicBrainz id.
Minstrel fetches no biographies or outside images, so none are sent.
- getLyrics (by artist and title) and getLyricsBySongId (OpenSubsonic
songLyrics, now declared) read lyrics when asked: a .lrc file beside the
song gives timed lyrics, otherwise the song's own lyrics tag.
- setRating accepts a rating and keeps none: a like is Minstrel's only
rating, and a low rating is never read as a dislike.
- getUsers lists every user, for an admin only.
ArtistRef no longer fixes its XML element name, so it can appear as
similarArtist; every field holding it names the element.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
An admin asking for another username got their own name and roles back.
The handler now looks the user up by exact username and answers with
that user's payload; an unknown username is ErrDataNotFound. A
non-admin asking about someone else is still ErrNotAuthorized.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Comment blocks in cmd/minstrel and 30 smaller internal packages, rewritten
to rule 32's standard with each citation read in context: task, milestone
and rule ids go, and so do the stories they were attached to ("used to",
"Before #N", measurements from one install, quotes, pointers to Fabled
Librarian's records and to docs/superpowers files that are not in the
repo). Where a story wrapped a real constraint, the constraint stays as a
present-tense fact.
Comments that had gone stale are corrected:
- taste.Config: the tuned values are overlaid by internal/recsettings;
it is no longer "a later follow-up".
- StorageConfig: the data dir holds art, caches and the stream secret,
not only playlist covers.
- the Subsonic album list and getUser comments describe what they do
today rather than a milestone that would change it.
Checked: the non-comment token stream of every changed file matches
HEAD, and gofmt -l is empty.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Feishin's first-login flow hits getUser to discover the authenticated
identity's roles. We never registered the route, so chi returned a
plain-text 404 — Feishin's parser treats anything non-Subsonic as a
generic auth failure ("Failed to log in"), masking the real cause.
- Implement /rest/getUser with the full role bag. Admins get every
role; non-admins get the play-music subset. Single-user M1 means
cross-user lookups by admins return the caller's roles for now;
revisit when user management lands.
- Set sub.NotFound on /rest/* to emit a Subsonic envelope (code 0,
"Method not implemented") instead of plain text. Any future client
probing an unimplemented endpoint now sees a parseable failure.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>