feat: use thumbnails from folders

+ cache failed lastfm scrobbles
+ implement lastfm scrobble filter
+ change /home to /nothome
This commit is contained in:
cwilvx
2025-01-07 23:13:19 +03:00
parent 2a12487220
commit fe39cadfdc
10 changed files with 136 additions and 31 deletions
+3 -4
View File
@@ -233,7 +233,7 @@ def get_track_group_stats(tracks: list[Track], is_album: bool = False):
"toptrack",
f"top track ({seconds_to_time_string(top_track.playduration)} listened)",
f"{top_track.title}",
top_track.image,
top_track.image + "?pathhash=" + top_track.pathhash if top_track else None,
)
if top_track
else StatItem(
@@ -251,7 +251,7 @@ def get_track_group_stats(tracks: list[Track], is_album: bool = False):
"playcount": 0,
"playduration": 0,
"title": track.album,
"image": track.image,
"image": track.image + "?pathhash=" + track.pathhash if track.image else None,
}
albums_map[track.albumhash]["playcount"] += 1
@@ -268,8 +268,7 @@ def get_track_group_stats(tracks: list[Track], is_album: bool = False):
"topalbum",
f"top album ({seconds_to_time_string(top_album['playduration'])} listened)",
f"{top_album['title']}",
top_album["image"],
)
top_album["image"])
if top_album
else StatItem(
"topalbum",