feature/add_merge_command #23

Merged
Hazel merged 3 commits from feature/add_merge_command into experimental 2024-05-07 12:15:08 +00:00
Showing only changes of commit 4f9261505e - Show all commits

View File

@ -403,19 +403,20 @@ class Page:
self.LOGGER.info(f"{song.option_string} already exists, thus not downloading again.")
return r
source = None
skip_intervals = []
if not found_on_disc:
for source in sources:
r = self.download_song_to_target(source=source, target=temp_target, desc=song.option_string)
if not r.is_fatal_error:
skip_intervals = self.get_skip_intervals(song, source)
break
if temp_target.exists:
r.merge(self._post_process_targets(
song=song,
temp_target=temp_target,
interval_list=[] if found_on_disc else self.get_skip_intervals(song, source)
interval_list=skip_intervals,
))
return r