cv-cat / Spider_XHS

小红书爬虫,小红书笔记、主页、搜索爬取
772 stars 150 forks source link

search.py里面可以设置保存用户头像吗 #25

Open CaptainChristmas opened 4 months ago

CaptainChristmas commented 4 months ago

我在profile.py看到有以下函数: def save_profile_info(self, url): profile = self.get_profile_info(url) print(f'开始保存用户{profile.nickname}基本信息') userId = profile.userId nickname = normstr(profile.nickname) path = f'./datas/{nickname}{userId}' check_and_create_path(path) download_media(path, 'avatar', profile.avatar, 'image', '用户头像') save_user_detail(path, profile) print(f'User {nickname} 信息保存成功') return profile

    但是不知道如何在search调用
cv-cat commented 4 months ago

参考profile.py

CaptainChristmas commented 4 months ago

这两天持续采集了大概三千条左右,发现出现了cookie有效但是一直保存失败的情况,显示无法查看什么的,这种情况怎么解决呢,我的课设还差一点就要采集完了哈哈哈哈哈,还望请教

------------------ 原始邮件 ------------------ 发件人: "cv-cat/Spider_XHS" @.>; 发送时间: 2024年3月19日(星期二) 中午1:27 @.>; 抄送: " @.**@.>; 主题: Re: [cv-cat/Spider_XHS] search.py里面可以设置保存用户头像吗 (Issue #25)

参考profile.py

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

cv-cat commented 4 months ago

github上开源的代码不太稳定会被风控,稳定的代码需联系作者获取  

?\ @.***

 

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2024年3月24日(星期天) 晚上7:59 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [cv-cat/Spider_XHS] search.py里面可以设置保存用户头像吗 (Issue #25)

这两天持续采集了大概三千条左右,发现出现了cookie有效但是一直保存失败的情况,显示无法查看什么的,这种情况怎么解决呢,我的课设还差一点就要采集完了哈哈哈哈哈,还望请教

------------------ 原始邮件 ------------------ 发件人: "cv-cat/Spider_XHS" @.>; 发送时间: 2024年3月19日(星期二) 中午1:27 @.>; 抄送: " @.**@.>; 主题: Re: [cv-cat/Spider_XHS] search.py里面可以设置保存用户头像吗 (Issue #25)

参考profile.py

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.> — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.>