{"record":{"id":"138f1707dc488950","repo":"immich-app/immich","slug":"no-valid-import-paths-found-for-library-library-id","errorCode":null,"errorMessage":"No valid import paths found for library ${library.id}","messagePattern":"No valid import paths found for library (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"server/src/services/library.service.ts","lineNumber":635,"sourceCode":"      this.logger.debug(`Library ${job.id} not found, skipping refresh`);\n      return JobStatus.Skipped;\n    }\n\n    this.logger.debug(`Validating import paths for library ${library.id}...`);\n\n    const validImportPaths: string[] = [];\n\n    for (const importPath of library.importPaths) {\n      const validation = await this.validateImportPath(importPath);\n      if (validation.isValid) {\n        validImportPaths.push(path.normalize(importPath));\n      } else {\n        this.logger.warn(`Skipping invalid import path: ${importPath}. Reason: ${validation.message}`);\n      }\n    }\n\n    if (validImportPaths.length === 0) {\n      this.logger.warn(`No valid import paths found for library ${library.id}`);\n\n      return JobStatus.Skipped;\n    }\n\n    const pathsOnDisk = this.storageRepository.walk({\n      pathsToCrawl: validImportPaths,\n      includeHidden: false,\n      exclusionPatterns: library.exclusionPatterns,\n      take: JOBS_LIBRARY_PAGINATION_SIZE,\n    });\n\n    let importCount = 0;\n    let crawlCount = 0;\n\n    this.logger.log(`Starting disk crawl of ${validImportPaths.length} import path(s) for library ${library.id}...`);\n\n    for await (const pathBatch of pathsOnDisk) {\n      crawlCount += pathBatch.length;","sourceCodeStart":617,"sourceCodeEnd":653,"githubUrl":"https://github.com/immich-app/immich/blob/e55ac299a4ec7cb372e35dbf2c6c05ee9ce77f6c/server/src/services/library.service.ts#L617-L653","documentation":"During external-library sync, if every configured import path failed validation, there is nothing to crawl, so the sync job short-circuits with JobStatus.Skipped and this warning is logged naming the library id. It means the library is effectively unusable in its current configuration.","triggerScenarios":"handleQueueSyncFiles runs and all entries in library.importPaths fail validateImportPath (missing, unreadable, disallowed, or unmounted paths).","commonSituations":"Entire external volume offline at sync time; library paths configured before the storage was mounted; container restarted without the volume bind; all paths moved after a reorganization.","solutions":["Fix or remove all invalid import paths shown by the per-path warnings for this library","Verify the storage volume is mounted inside the container before triggering sync","Re-validate paths and re-run library sync from the admin UI","Check library id in the log matches the library you intended to configure"],"exampleFix":"// before\nif (validImportPaths.length === 0) { this.logger.warn(`No valid import paths found for library ${library.id}`); return JobStatus.Skipped; }\n// after\n// ensure volume mounted then re-sync\n// docker compose up -d  # with ./library:/path/to/library:ro\nif (validImportPaths.length === 0) { this.logger.warn(`No valid import paths found for library ${library.id}`); return JobStatus.Skipped; }","handlingStrategy":"validation","validationCode":"const checks = await Promise.all(library.importPaths.map(async (p) => ({ p, ok: await importPathUsable(p) })));\nif (checks.every((c) => !c.ok)) throw new Error(`Library ${library.id} has no usable import paths`);","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Health-check mounts before triggering library sync","Configure at least one always-available import path per library","Alert on JobStatus.Skipped for sync jobs","Re-sync after container/volume restarts"],"tags":["library","configuration","sync"],"backgroundTag":"empty-result-set","analyzedSha":"e55ac299a4ec7cb372e35dbf2c6c05ee9ce77f6c","analyzedAt":"2026-09-15T07:20:19.675Z","contentChangedAt":"2026-09-15T07:20:19.675Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}