Skip to content

fix: prevent --only-print-filenames from downloading during live phot… #1220#1238

Merged
AndreyNikiforov merged 2 commits intoicloud-photos-downloader:masterfrom
AndreyNikiforov:fix/issue-1220-only-print-filenames-dedup-bug
Aug 31, 2025
Merged

fix: prevent --only-print-filenames from downloading during live phot… #1220#1238
AndreyNikiforov merged 2 commits intoicloud-photos-downloader:masterfrom
AndreyNikiforov:fix/issue-1220-only-print-filenames-dedup-bug

Conversation

@AndreyNikiforov
Copy link
Copy Markdown
Collaborator

…o deduplication

Fixes issue #1220 where --only-print-filenames would still download live photo video files during deduplication. The bug occurred because the deduplication logic would change the filename and reset file_exists to False, causing the download to proceed despite only_print_filenames=True.

Changes:

  • Restructured live photo handling logic in download_builder()
  • Added proper only_print_filenames check during deduplication
  • Ensures deduplicated filenames are printed without triggering downloads
  • Added comprehensive test case to prevent regression

🤖 Generated with Claude Code

AndreyNikiforov and others added 2 commits August 31, 2025 03:44
…o deduplication

Fixes issue icloud-photos-downloader#1220 where --only-print-filenames would still download
live photo video files during deduplication. The bug occurred because
the deduplication logic would change the filename and reset file_exists
to False, causing the download to proceed despite only_print_filenames=True.

Changes:
- Restructured live photo handling logic in download_builder()
- Added proper only_print_filenames check during deduplication
- Ensures deduplicated filenames are printed without triggering downloads
- Added comprehensive test case to prevent regression

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
Fix test failure on Windows platform by using os.path.join()
instead of hardcoded forward slashes for path construction.
This ensures the test works correctly on both Unix and Windows systems.

Windows was returning: ['2018\\07\\31\\IMG_7409.MOV']
Test expected: ['2018/07/31\\IMG_7409.MOV']
Fixed to use: os.path.join("2018", "07", "31", "IMG_7409.MOV")

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
@AndreyNikiforov AndreyNikiforov merged commit df2ba11 into icloud-photos-downloader:master Aug 31, 2025
28 checks passed
@AndreyNikiforov AndreyNikiforov deleted the fix/issue-1220-only-print-filenames-dedup-bug branch August 31, 2025 07:31
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