Skip to content

fix(photos): chunk exiftool calls to prevent timeout on large imports#46

Merged
arthware-dev merged 1 commit into
mainfrom
feat/photos-album-cli
Jul 6, 2026
Merged

fix(photos): chunk exiftool calls to prevent timeout on large imports#46
arthware-dev merged 1 commit into
mainfrom
feat/photos-album-cli

Conversation

@arthware-dev

@arthware-dev arthware-dev commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Exiftool year extraction processes files in chunks of 200 (was: entire batch in one call)
  • File paths passed via stdin (-@ -) instead of CLI arguments to avoid OS arg-length limits
  • Added -fast flag so exiftool only reads metadata headers, not full files
  • Timeout on a chunk falls back to filename-based year detection instead of crashing

Fixes Command timed out error during --album-per-year imports with large PSD/TIF files.

Exiftool was invoked once with all file paths as CLI arguments. On
batches with large files (PSD, TIF), this exceeded the timeout and
could hit OS argument length limits.

- Process 200 files per chunk with paths piped via stdin (-@ -)
- Use -fast flag to skip full file reads (metadata headers only)
- Gracefully fall back to filename patterns on timeout
@arthware-dev
arthware-dev force-pushed the feat/photos-album-cli branch from b7c19fa to 83fe438 Compare July 3, 2026 20:14
@arthware-dev arthware-dev changed the title Feat/photos album cli fix(photos): chunk exiftool calls to prevent timeout on large imports Jul 3, 2026
@arthware-dev
arthware-dev merged commit f7380d5 into main Jul 6, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant