[gnome-music/wip/mschraal/fix-art-lookup-stalls: 1/2] embeddedart: Do not stop loading on duplication




commit 96d4ddccf0e324bccf72c1e01a800c88ac045737
Author: Marinus Schraal <mschraal gnome org>
Date:   Sun Apr 24 00:34:59 2022 +0200

    embeddedart: Do not stop loading on duplication
    
    When a file already existed Music stopped the async lookup run, blocking
    the async queue.
    
    When a file already exists, emit the art-found signal so the async art
    lookup continues.

 gnomemusic/embeddedart.py | 1 +
 1 file changed, 1 insertion(+)
---
diff --git a/gnomemusic/embeddedart.py b/gnomemusic/embeddedart.py
index 0de00f791..ec3e7932b 100644
--- a/gnomemusic/embeddedart.py
+++ b/gnomemusic/embeddedart.py
@@ -177,6 +177,7 @@ class EmbeddedArt(GObject.GObject):
         except GLib.Error as error:
             # File already exists.
             self._log.info(f"Error: {error.domain}, {error.message}")
+            self.emit("art-found", True)
         else:
             pixbuf.save_to_streamv_async(
                 output_stream, "jpeg", None, None, None,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]