{"record":{"id":"03ef3fce57b765db","repo":"spacedriveapp/spacedrive","slug":"no-library-selected","errorCode":null,"errorMessage":"No library selected","messagePattern":"No library selected","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"apps/mobile/src/client/SpacedriveClient.ts","lineNumber":140,"sourceCode":"    method: string,\n    input: unknown = {},\n  ): Promise<T> {\n    const wireMethod = (WIRE_METHODS.coreQueries as any)[method];\n    if (!wireMethod) {\n      throw new Error(`Unknown core query: ${method}`);\n    }\n    return this.transport.request<T>(wireMethod, { input });\n  }\n\n  /**\n   * Execute a library-level query.\n   */\n  async libraryQuery<T = unknown>(\n    method: string,\n    input: unknown = {},\n  ): Promise<T> {\n    if (!this.currentLibraryId) {\n      throw new Error(\"No library selected\");\n    }\n\n    const wireMethod = (WIRE_METHODS.libraryQueries as any)[method];\n    if (!wireMethod) {\n      throw new Error(`Unknown library query: ${method}`);\n    }\n\n    return this.transport.request<T>(wireMethod, {\n      input,\n      library_id: this.currentLibraryId,\n    });\n  }\n\n  /**\n   * Execute a core-level action (mutation).\n   */\n  async coreAction<T = unknown>(\n    method: string,","sourceCodeStart":122,"sourceCodeEnd":158,"githubUrl":"https://github.com/spacedriveapp/spacedrive/blob/6dfeccf2113039e35f2ce735f945e70dc3e4ea45/apps/mobile/src/client/SpacedriveClient.ts#L122-L158","documentation":"A wrapper error from the thumbstrip processor: super::generate_thumbstrip_for_file returned Err and the processor wraps it with 'Thumbstrip generation failed: {e}'. The real cause is in the appended inner error string — typically ffmpeg invocation failures, unreadable/corrupt video files, or failures writing variant outputs. The wrapping preserves the inner message, so read the text after the colon.","triggerScenarios":"Calling the thumbstrip processor on a video/ entry (MIME starts with video/) where generate_thumbstrip_for_file fails: ffmpeg/ffprobe not found in the daemon's PATH, a truncated or non-decodable video, missing write permissions or full disk at the thumbstrip variants directory.","commonSituations":"Daemon running in an environment (service, container, launchd) whose PATH lacks ffmpeg; partially downloaded/synced video files; codec unsupported by the installed ffmpeg build; variants cache directory owned by another user.","solutions":["Read the inner error after 'Thumbstrip generation failed:' — it names the actual failing step.","Verify ffmpeg (and ffprobe) are installed and reachable from the daemon's environment: run `ffmpeg -version` with the same env/user as sd-daemon.","Check the source file plays: `ffprobe <entry.path>` from the same machine.","Check write permissions and free space in the library's thumbstrip variants directory.","Re-run with RUST_LOG=sd_core::ops::media=debug to get the per-file debug lines (→ Generating thumbstrip for ...) pinpointing the entry."],"exampleFix":"# before\nsystemctl start sd-daemon   # ffmpeg not on daemon PATH\n\n# after\nEnvironment=\"PATH=/usr/local/bin:/usr/bin:/bin\"  # add dir containing ffmpeg to the daemon unit\nsystemctl restart sd-daemon","handlingStrategy":"try-catch","validationCode":"// Pre-flight: file exists, is readable, and ffmpeg is on PATH before processing.\nuse std::path::Path;\n\nfn can_attempt_thumbstrip(path: &Path) -> bool {\n    path.is_file() && which::which(\"ffmpeg\").is_ok()\n}","typeGuard":null,"tryCatchPattern":"// Per-file isolation: one bad video must not abort the batch.\nmatch generate_thumbstrip_for_file(&library, &uuid, &path, &variants, regenerate).await {\n    Ok(n) => tracing::info!(count = n, \"thumbstrip ok\"),\n    Err(e) => {\n        tracing::warn!(path = %path.display(), error = %e, \"thumbstrip failed, skipping file\");\n        // record failure against the entry and continue\n    }\n}","preventionTips":["Ship/verify ffmpeg availability in the daemon environment (container image, systemd unit PATH).","Skip entries whose file is missing or zero-sized before invoking generation.","Surface the inner error (after the colon) in dashboards — the wrapper alone is not actionable."],"tags":["rust","media","ffmpeg","thumbstrip","wrapper-error"],"backgroundTag":null,"analyzedSha":"6dfeccf2113039e35f2ce735f945e70dc3e4ea45","analyzedAt":"2026-08-16T11:26:17.074Z","schemaVersion":2},"datasetVersion":"2026-08-16T13:17:31.715Z"}