Less restrictive filter + convert rating
This commit is contained in:
@@ -102,10 +102,18 @@ class ITunesGraphParser:
|
|||||||
track = tracks[k]
|
track = tracks[k]
|
||||||
|
|
||||||
# Filter out any non-music with ratings lower than 3 stars
|
# Filter out any non-music with ratings lower than 3 stars
|
||||||
if (track['Track Type'] != 'File') or ('Artist' not in track) or ('Genre' not in track) or (
|
if (track['Track Type'] != 'File') or ('Artist' not in track) or ('Genre' not in track):
|
||||||
'Rating' not in track) or (track['Rating'] < self._rating) or (track['Artist'] == 'Various Artists'):
|
# After a lot of investigation, songs without these properties are really problematic
|
||||||
|
# (songs that need to be relocated, podcast, etc.)
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
# Convert rating - needed for calculation later
|
||||||
|
if ('Rating' not in track):
|
||||||
|
if ('Album Rating' not in track):
|
||||||
|
track['Rating'] = 0
|
||||||
|
else:
|
||||||
|
track['Rating'] = track['Album Rating']
|
||||||
|
|
||||||
akey = track['Artist']
|
akey = track['Artist']
|
||||||
if akey not in self._artists:
|
if akey not in self._artists:
|
||||||
self._artists[akey] = {
|
self._artists[akey] = {
|
||||||
|
|||||||
Reference in New Issue
Block a user