|
马上注册,结交更多好友,享用更多功能^_^
您需要 登录 才可以下载或查看,没有账号?立即注册
x
import requests
from bs4 import BeautifulSoup
import time
for i in range(1,6):
url=f"https://www.shixiseng.com/interns?page={i}&type=intern&keyword=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90&area=&months=&days=°ree=&official=&enterprise=&salary=-0&publishTime=&sortType=&city=%E5%85%A8%E5%9B%BD&internExtend="
headers={"User-Agent"="Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36"}
res=requests.get(url,headers=headers)
html=res.text
soup=BeautifulSoup(html,"lxml")
titles=soup.find_all(class_="title ellipsis font")
for item in titles:
detail_url=item.attrs["href"]
time.sleep(2)
print(detail_url)
time.sleep(2)
这是我的爬虫代码,但是运行结果提示的是:
C:\Users\HP\Desktop\python.exe "D:\新建文件夹\python process\Doc\数据分析岗位整理.py"
Process finished with exit code -1073741515 (0xC0000135)
这是怎么回事呢?要怎么解决呢?我百度一下说让检查python版本,我的版本是3.11.9,又说让检查依赖库,我依赖库都安装好了呀,还让我检查环境变量,怎么检查环境变量呢? |
|