Closed fangshu1999 closed 3 years ago
感谢反馈。
你的config.json应该是旧的,现在有增加了很多配置(https://github.com/dataabc/weiboSpider/blob/master/weibo_spider/config_sample.json),包括end_date,更新项目源代码就可以了。
如果还有问题欢迎继续讨论
我运行python3 -m weibo_spide后 没有反应
@zzfiu
感谢反馈。
可能你本地只有python3一个版本,可以运行
$ python -m weibo_spider
如果还有问题,欢迎继续讨论
C:\Users\Administrator\AppData\Local\Programs\Python\Python38\python.exe: No module named weibo_spider 出现这个
@zzfiu
你应该在weiboSpider目录下运行这个命令,就是cd到weiboSpider目录,然后运行命令python -m weibo_spider
感谢反馈。
你的config.json应该是旧的,现在有增加了很多配置(https://github.com/dataabc/weiboSpider/blob/master/weibo_spider/config_sample.json),包括end_date,更新项目源代码就可以了。
如果还有问题欢迎继续讨论
如果之前已经运行并生成过程序的话只通过 git pull 来更新源代码似乎还不足够, 因为当前目录下已经生成过 config.json 的话并不会去覆盖已有的 config.json,需要
当前如果并不是通过 git pull 更新而是直接重新下载了新的软件包的话等价于上面的 2.
@songzy12
是的,考虑过加个提示,一旦出现上面的错误,就提示使用者更新config,只是觉得参数更新不频繁,出现上述问题的概率不高,就没有添加。
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Closing as stale, please reopen if you'd like to work on this further.
为了更好的解决问题,请认真回答下面的问题。等到问题解决,请及时关闭本issue。
问:请您指明哪个版本运行出错(github版/PyPi版/全部)?
答:GitHub
问:您使用的是否是最新的程序(是/否)?
答:是
问:爬取任意用户都会运行出错吗(是/否)?
答:是
问:若只有爬特定微博时才出错,能否提供出错微博的weibo_id或url(非必填)?
答:
问:若您已提供出错微博的weibo_id或url,可忽略此内容,否则能否提供出错账号的user_id及您配置的since_date,方便我们定位出错微博(非必填)?
答:
问:如果方便,请您描述出错详情,最好附上错误提示。
答: 在weibo_spider目录下运行python3 -m weibo_spider报错 'end_date' Traceback (most recent call last): File "/Users/fangshu/weiboSpider/weibo_spider/spider.py", line 313, in main config_util.validate_config(config) File "/Users/fangshu/weiboSpider/weibo_spider/config_util.py", line 39, in validate_config end_date = str(config['end_date']) KeyError: 'end_date'