tonhowtf/omniget · warning
[player] failed loading player settings
Error message
[player] failed loading player settings
What it means
The Tauri plugin call study:music:player:settings:get threw while hydrating the music player store at startup; the console logs this message and keeps defaults (autoSkipOnError=false). The store is marked loaded beforehand, so the failure only means persisted settings could not be fetched — the player continues with defaults, best-effort.
Solutions
- Check the logged cause (plugin missing vs storage error)
- Verify the study plugin is registered and the command name is correct
- Fall back to the default autoSkipOnError value (code already does via !!res?)
- Retry the settings load after plugin readiness
Example fix
// before
catch (e) {
console.warn("[player] failed loading player settings", e);
}
// after
catch (e) {
console.warn("[player] failed loading player settings, keeping default", e);
this.autoSkipOnError = false;
} Defensive patterns
Strategy: fallback
Validate before calling
if (!pluginReady("study")) {
console.warn("[player] study plugin not ready; using default player settings");
return;
} Type guard
function hasAutoSkipSetting(s: unknown): s is { auto_skip_on_error?: boolean } {
return !!s && typeof s === "object";
} Try / catch
try {
const res = await pluginInvoke("study", "study:music:player:settings:get", {});
this.autoSkipOnError = !!res?.auto_skip_on_error;
} catch (e) {
console.warn("[player] failed loading player settings, keeping default", e);
this.autoSkipOnError = false;
} Prevention
- Load settings only after the plugin signals readiness
- Always initialize settings fields with sane defaults
- Log and retry once on transient transport errors
- Keep the backend command names versioned/consistent
When it happens
Trigger: pluginInvoke("study", "study:music:player:settings:get", {}) rejects — plugin/backend not ready, command missing, or storage layer error.
Common situations: Plugin not registered/started yet at store init, backend version without the settings:get command, or corrupted/unavailable settings storage.
Understand the failure class
Background: "missing required config value" errors: why libraries refuse to start when a configuration key is empty, unset, or blank — this error's family across 48 libraries.
Related errors
- [player] failed loading spotify settings
- external_data_cache: plugin_id must not be empty
- external_data_cache: namespace must not be empty
- external_data_cache: plugin_id/namespace must not contain…
- plugin id must not be empty
AI-assisted analysis of tonhowtf/omniget@8600b91f42 (2026-09-12).
Data as JSON: /api/errors/d260228b22c7e30f.
Report an issue: GitHub.
Appendix: source
Thrown at src/lib/study-music/player-store.svelte.ts:511
void this.loadSpotifySettings();
void this.loadRpcSettings();
if (this.queue.some((t) => t.source === "spotify" && t.spotify_uri)) {
void spotifySdk.ensureLoaded().catch(() => {
/* prewarm best-effort */
});
}
}
private async loadPlayerSettings() {
if (this.playerSettingsLoaded) return;
this.playerSettingsLoaded = true;
try {
const res = await pluginInvoke<{
auto_skip_on_error?: boolean;
}>("study", "study:music:player:settings:get", {});
this.autoSkipOnError = !!res?.auto_skip_on_error;
} catch (e) {
console.warn("[player] failed loading player settings", e);
}
}
async setAutoSkipOnError(value: boolean) {
this.autoSkipOnError = value;
try {
await pluginInvoke("study", "study:music:player:settings:set", {
auto_skip_on_error: value,
});
} catch (e) {
console.warn("[player] failed saving auto_skip_on_error", e);
}
}
private setError(err: PlayerError) {
this.lastError = err;
this.error = err.message || null;
this.status = "error";View on GitHub (pinned to 8600b91f42)