当前位置:网站首页>Quick access to video links at station B
Quick access to video links at station B
2022-07-06 21:19:00 【Listen to my call, rookie evolution】
from lxml import etree
import time
import json
import requests
import csv
import random
import os
from fake_useragent import UserAgent
headers={
'User-Agent':UserAgent().random
}
for i in range(1,35):
url='https://api.bilibili.com/x/web-interface/search/type?__refresh__=true&_extra=&context=&page={}&page_size=42&from_source=&from_spmid=333.337&platform=pc&highlight=1&single_column=0&keyword=%E8%8E%8E%E5%A3%AB%E6%AF%94%E4%BA%9A%E6%88%8F%E5%89%A7%E8%A1%A8%E6%BC%94&category_id=&search_type=video&dynamic_offset=72&preload=true&com2co=true'.format(i)
response=requests.get(url=url,headers=headers)
data=response.json()
cards=data['data']['result']
print(i)
for card in cards:
li=[]
link=card["arcurl"]# score
times=card["duration"]# Movie title
description=card["title"]#url
li.append(link)
li.append(times)
li.append(description)
print(li)
with open('biliok.csv', 'a', newline='', encoding='utf-8-sig') as fp:
writer = csv.writer(fp)
writer.writerow(li)
time.sleep(float(format(random.uniform(0,3), '.2f')))
边栏推荐
- 缓存更新策略概览(Caching Strategies Overview)
- Web开发小妙招:巧用ThreadLocal规避层层传值
- Ravendb starts -- document metadata
- Huawei device command
- Pat 1085 perfect sequence (25 points) perfect sequence
- Introduction to the use of SAP Fiori application index tool and SAP Fiori tools
- Data Lake (VIII): Iceberg data storage format
- 3D face reconstruction: from basic knowledge to recognition / reconstruction methods!
- 968 edit distance
- R语言做文本挖掘 Part4文本分类
猜你喜欢
Four common ways and performance comparison of ArrayList de duplication (jmh performance analysis)
20220211 failure - maximum amount of data supported by mongodb
[redis design and implementation] part I: summary of redis data structure and objects
OneNote in-depth evaluation: using resources, plug-ins, templates
After working for 5 years, this experience is left when you reach P7. You have helped your friends get 10 offers
互联网快讯:吉利正式收购魅族;胰岛素集采在31省全面落地
每个程序员必须掌握的常用英语词汇(建议收藏)
Seven original sins of embedded development
This year, Jianzhi Tencent
Aike AI frontier promotion (7.6)
随机推荐
Four common ways and performance comparison of ArrayList de duplication (jmh performance analysis)
Nodejs tutorial let's create your first expressjs application with typescript
[in depth learning] pytorch 1.12 was released, officially supporting Apple M1 chip GPU acceleration and repairing many bugs
OAI 5g nr+usrp b210 installation and construction
js通过数组内容来获取数组下标
Le langage r visualise les relations entre plus de deux variables de classification (catégories), crée des plots Mosaiques en utilisant la fonction Mosaic dans le paquet VCD, et visualise les relation
2022菲尔兹奖揭晓!首位韩裔许埈珥上榜,四位80后得奖,乌克兰女数学家成史上唯二获奖女性
[interpretation of the paper] machine learning technology for Cataract Classification / classification
FZU 1686 龙之谜 重复覆盖
Internet News: Geely officially acquired Meizu; Intensive insulin purchase was fully implemented in 31 provinces
[MySQL] trigger
Acdreamoj1110 (multiple backpacks)
Study notes of grain Mall - phase I: Project Introduction
039. (2.8) thoughts in the ward
How do I remove duplicates from the list- How to remove duplicates from a list?
20220211 failure - maximum amount of data supported by mongodb
OSPF multi zone configuration
Infrared thermometer based on STM32 single chip microcomputer (with face detection)
R language for text mining Part4 text classification
@Detailed differences among getmapping, @postmapping and @requestmapping, with actual combat code (all)