Fix key error for artist pages caused by removal of video title link (server-side change)
This commit is contained in:
parent
c99efe7e5b
commit
20e44873d3
2 changed files with 3 additions and 2 deletions
|
|
@ -12,6 +12,7 @@ PLAY_BUTTON = [
|
|||
]
|
||||
NAVIGATION_BROWSE_ID = ['navigationEndpoint', 'browseEndpoint', 'browseId']
|
||||
NAVIGATION_VIDEO_ID = ['navigationEndpoint', 'watchEndpoint', 'videoId']
|
||||
NAVIGATION_PLAYLIST_ID = ['navigationEndpoint', 'watchEndpoint', 'playlistId']
|
||||
CAROUSEL_TITLE = ['header', 'musicCarouselShelfBasicHeaderRenderer', 'title', 'runs', 0]
|
||||
FRAMEWORK_MUTATIONS = ['frameworkUpdates', 'entityBatchUpdate', 'mutations']
|
||||
TITLE = ['title', 'runs', 0]
|
||||
|
|
|
|||
|
|
@ -299,8 +299,8 @@ class YTMusic:
|
|||
result['browseId'] = nav(item, TITLE + NAVIGATION_BROWSE_ID)
|
||||
elif category == 'videos':
|
||||
result['views'] = nav(item, SUBTITLE2).split(' ')[0]
|
||||
result['videoId'] = nav(item, TITLE + NAVIGATION_VIDEO_ID)
|
||||
result['playlistId'] = nav(item, TITLE + NAVIGATION_VIDEO_ID)
|
||||
result['videoId'] = nav(item, NAVIGATION_VIDEO_ID)
|
||||
result['playlistId'] = nav(item, NAVIGATION_PLAYLIST_ID)
|
||||
artist[category]['results'].append(result)
|
||||
|
||||
return artist
|
||||
|
|
|
|||
Loading…
Reference in a new issue