dataabc / weibo-crawler

新浪微博爬虫,用python爬取新浪微博数据,并下载微博图片和微博视频
3.25k stars 739 forks source link

TypeError: ‘str‘ object does not support item assignment #365

Open Xufeng98 opened 1 year ago

Xufeng98 commented 1 year ago

单个ID不存在问题,当读入的是txt文件时,会出现此错误 image

dataabc commented 1 year ago

双引号错了。

dontd1eplz commented 1 year ago

您好,我遇到了相同的问题,我检查了一下双引号确定是半角模式下的英文双引号,请问应该如何改正呢?

Xufeng98 commented 1 year ago

还未解决,我目前在用cookie 版本的代码在跑


发件人: dontd1eplz @.> 发送时间: Monday, May 8, 2023 10:37:05 PM 收件人: dataabc/weibo-crawler @.> 抄送: BryceFeng98 @.>; Author @.> 主题: Re: [dataabc/weibo-crawler] TypeError: ‘str‘ object does not support item assignment (Issue #365)

您好,我遇到了相同的问题,我检查了一下双引号确定是半角模式下的英文双引号,请问应该如何改正呢?

― Reply to this email directly, view it on GitHubhttps://github.com/dataabc/weibo-crawler/issues/365#issuecomment-1538469480, or unsubscribehttps://github.com/notifications/unsubscribe-auth/A6CR5AMUJ36EU5UHAHZN6STXFEAJDANCNFSM6AAAAAAXW3JBSQ. You are receiving this because you authored the thread.Message ID: @.***>

dataabc commented 1 year ago

@BryceFeng98 @dontd1eplz 把92行shuffle代码注释看看。

dontd1eplz commented 1 year ago

谢谢,将random.shuffle(user_id_list)注释掉后顺利运行