【发布时间】:2018-05-19 05:40:22
【问题描述】:
我正在尝试使用 python 库“google_news_crawler”,当我运行它的示例代码时,它可以通过“pip install google_news_crawler”安装。
google_news_crawler --datastore=ES --feed="http://news.google.com/news?cf=all&ned=en_bw&output=rss&topic=t&sort=newest"
它给了我这样的错误:
-HP-Notebook:~$ google_news_crawler --datastore=ES --feed="http://news.google.com/news?cf=all&ned=en_bw&output=rss&topic=t&sort=newest"
Traceback (most recent call last):
File "/usr/local/bin/google_news_crawler", line 11, in <module>
sys.exit(main())
File "/usr/local/lib/python2.7/dist-packages/google_news_crawler/google_news_crawler.py", line 46, in main
setup_logging(args['--log-config'])
File "/usr/local/lib/python2.7/dist-packages/google_news_crawler/google_news_crawler.py", line 36, in setup_logging
with open(fname) as f:
IOError: [Errno 2] No such file or directory: 'logging.yaml'
我真的不知道什么是“logging.yaml”文件以及如何解决这个错误。
谢谢
【问题讨论】:
-
尝试从项目的 repo 复制该文件,bitbucket.org/ilps/google_news_crawler/src