为什么不从YouTube获取任何“ a”标签?

我正在尝试通过BeautifulSoup从给定的输入通道链接获取视频的所有链接。我发现视频的所有“ a”标签的ID均为“ video-title”,但以下代码未提供任何输出:

import requests
from bs4 import BeautifulSoup

source = requests.get('https://www.youtube.com/user/TheCraftingLab/featured').text
soup = BeautifulSoup(source, 'html.parser')

container = soup.findAll("a", {id: "video-title"})
for i in container:
    print(i)

What's wrong? enter image description here

评论