redesign progressbars

+ hide some progressbars
+ rewrite telemetry into a class
+ remove obsolete start info logs
+ update contributing.md to include contributing.md
+ send posthog event in a bg thread
+ related side effects
This commit is contained in:
mungai-njoroge
2023-09-27 17:18:52 +03:00
parent 54714a224b
commit 4f757e989f
20 changed files with 144 additions and 130 deletions
+1 -1
View File
@@ -8,12 +8,12 @@ import requests
from PIL import Image, UnidentifiedImageError
from requests.exceptions import ConnectionError as RequestConnectionError
from requests.exceptions import ReadTimeout
from tqdm import tqdm
from app import settings
from app.models import Album, Artist, Track
from app.store import artists as artist_store
from app.utils.hashing import create_hash
from app.utils.progressbar import tqdm
CHECK_ARTIST_IMAGES_KEY = ""
+1 -1
View File
@@ -6,7 +6,6 @@ import json
from pathlib import Path
import colorgram
from tqdm import tqdm
from app import settings
from app.db.sqlite.albumcolors import SQLiteAlbumMethods as aldb
@@ -17,6 +16,7 @@ from app.store.artists import ArtistStore
from app.store.albums import AlbumStore
from app.logger import log
from app.lib.errors import PopulateCancelledError
from app.utils.progressbar import tqdm
PROCESS_ALBUM_COLORS_KEY = ""
PROCESS_ARTIST_COLORS_KEY = ""
+1 -1
View File
@@ -5,7 +5,6 @@ from typing import Generator
from requests import ConnectionError as RequestConnectionError
from requests import ReadTimeout
from tqdm import tqdm
from app import settings
from app.db.sqlite.favorite import SQLiteFavoriteMethods as favdb
@@ -28,6 +27,7 @@ from app.store.artists import ArtistStore
from app.store.tracks import TrackStore
from app.utils.filesystem import run_fast_scandir
from app.utils.network import has_connection
from app.utils.progressbar import tqdm
get_all_tracks = SQLiteTrackMethods.get_all_tracks
insert_many_tracks = SQLiteTrackMethods.insert_many_tracks
+1 -2
View File
@@ -3,11 +3,10 @@ This library contains all the functions related to tracks.
"""
import os
from tqdm import tqdm
from app.db.sqlite.tracks import SQLiteTrackMethods as tdb
from app.store.tracks import TrackStore
from app.utils.progressbar import tqdm
def validate_tracks() -> None:
"""