mirror of
https://git.sr.ht/~cadence/NewLeaf
synced 2024-11-25 00:47:29 +00:00
Fix broken channel videos extraction failing with KeyError: 'gridVideoRenderer'
This commit is contained in:
parent
0ae2a8a126
commit
80b41c7725
@ -58,7 +58,7 @@ def extract_channel(ucid):
|
|||||||
# with messageRenderer.text.simpleText == "This channel has no videos."
|
# with messageRenderer.text.simpleText == "This channel has no videos."
|
||||||
if "gridRenderer" in tab_parts:
|
if "gridRenderer" in tab_parts:
|
||||||
videos = (
|
videos = (
|
||||||
v["gridVideoRenderer"] for v in tab_parts["gridRenderer"]["items"]
|
v["gridVideoRenderer"] for v in tab_parts["gridRenderer"]["items"] if "gridVideoRenderer" in v
|
||||||
)
|
)
|
||||||
for v in videos:
|
for v in videos:
|
||||||
live = True
|
live = True
|
||||||
|
Loading…
Reference in New Issue
Block a user