feat(db): fold every migration into one baseline at version 106
release / web (push) Successful in 1m13s
release / go (push) Successful in 1m48s
release / govulncheck (push) Successful in 18s
release / integration (push) Successful in 3m56s
release / android (push) Successful in 4m19s
release / Build signed APK (push) Successful in 4m40s
release / Attach APK to the Release (tag releases only) (push) Skipped
release / Build + push container image (push) Successful in 14s
release / Verify release artifacts (tag releases only) (push) Skipped

0106_baseline.up.sql is the schema at version 106 and the settings rows
it starts with, taken from a database migrated through 0001–0106; a
database built from the baseline alone dumps identically. A database
already at 106 skips it. Comments that pointed at a migration number now
name the table or constraint instead.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-23 00:57:18 -05:00
co-authored by Claude Opus 5.5
parent 13df3d756d
commit 285a24f0ab
247 changed files with 1480 additions and 4200 deletions
+1 -1
View File
@@ -67,7 +67,7 @@ func (h *handlers) handleUpdateFingerprintSettings(w http.ResponseWriter, r *htt
AutoResolve: autoResolve,
})
if err != nil {
// Validation mirrors migration 0061's CHECKs and names the field.
// Validation mirrors fingerprint_settings's CHECKs and names the field.
if errors.Is(err, library.ErrFingerprintSettingOutOfRange) {
writeErr(w, apierror.BadRequest("invalid_setting", err.Error()))
return
+1 -1
View File
@@ -15,7 +15,7 @@ import (
)
// validDiagnosticKinds is the COARSE category whitelist. Mirrors the
// CHECK constraint in migration 0036 — keep both in sync (per the
// CHECK constraint on diagnostic_events.kind — keep both in sync (per the
// enum-CHECK-whitelist rule). The finer event discriminator + all
// event-specific fields live inside each event's payload, so new event
// variants do NOT require a new category here.
+1 -1
View File
@@ -213,7 +213,7 @@ func (h *handlers) handleGetRecommendationMetrics(w http.ResponseWriter, r *http
}
// pickKindLabels is the display vocabulary for play_events.pick_kind
// values (mirrors the CHECK in migration 0041). Every system mix that
// values (mirrors the CHECK on play_events.pick_kind). Every system mix that
// stamps provenance gets its breakdown from this one map — adding a
// stamping mix needs no metrics change.
var pickKindLabels = map[string]string{
+1 -1
View File
@@ -13,7 +13,7 @@ import (
// The Subsonic password is for clients that sign in with Subsonic's t/s
// scheme (md5 of the password plus a salt). Checking that needs the password
// itself, so it is stored readable (migration 0003). That is why Minstrel
// itself, so it is stored readable (users.subsonic_password). That is why Minstrel
// generates it rather than letting the user choose one: a generated value
// can never be a login password reused from somewhere else, so a leaked
// users table gives up access to this server's /rest API and nothing more.
+1 -1
View File
@@ -14,7 +14,7 @@ import (
"git.fabledsword.com/bvandeusen/minstrel/internal/db/dbq"
)
// Valid `kind` values. Mirrors the CHECK constraint in migration 0032
// Valid `kind` values. Mirrors playback_errors_kind_check
// — keep both lists in sync if you add a kind here, otherwise inserts
// pass the handler whitelist and trip the DB constraint instead.
var validPlaybackErrorKinds = map[string]struct{}{