Scrapy - logging to file and stdout simultaneously, with spider names

后端 未结 7 1850
悲&欢浪女
悲&欢浪女 2021-01-30 18:28

I\'ve decided to use the Python logging module because the messages generated by Twisted on std error is too long, and I want to INFO level meaningful messages such

7条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-30 19:13

    ScrapyFileLogObserver is no longer supported. You may use standard python logging module.

    import logging
    logging.getLogger().addHandler(logging.StreamHandler())
    

提交回复
热议问题