fix importfeed --force skip behavior reversion
authorJoey Hess <joeyh@joeyh.name>
Fri, 2 Feb 2024 19:57:07 +0000 (15:57 -0400)
committerJoey Hess <joeyh@joeyh.name>
Fri, 2 Feb 2024 19:57:07 +0000 (15:57 -0400)
importfeed --force: Don't treat it as a failure when an already downloaded
file exists. (Fixes a behavior change introduced in 10.20230626.)

04ee6c4c6b2 caused the reversion. Inside a CommandPerform, stop causes it
to fail. Before that commit, it was inside a CommandStart, where stop
causes it to skip.

CHANGELOG
Command/ImportFeed.hs

index d0f759cc6afd6094c046f603fa5a943fcf8cd035..2a751cfd7ad8085706e4e264cc77190b08d5ec76 100644 (file)
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -2,6 +2,9 @@ git-annex (10.20240130) UNRELEASED; urgency=medium
 
   * importfeed: Added --scrape option, which uses yt-dlp to screen scrape
     the equivilant of an RSS feed.
+  * importfeed --force: Don't treat it as a failure when an already
+    downloaded file exists. (Fixes a behavior change introduced in
+    10.20230626.)
   * importfeed --force: Avoid creating duplicates of existing
     already downloaded files when yt-dlp or a special remote was used.
 
index dbc8cb8bf0f056de6ad1ed822deff13c270be3f9..a8d04ef2dafe28c319536aa39d63f58bf24d2ed6 100644 (file)
@@ -412,7 +412,7 @@ runDownload todownload url extension cache cv getter = do
        case dest of
                Nothing -> do
                        recordsuccess
-                       stop
+                       next $ return True
                Just f -> getter (toRawFilePath f) >>= \case
                        Just ks
                                -- Download problem.