/ Published in: Python
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
# Redirect Scrapy log messages to standard Python logger ## Add the following lines to your Scrapy project's settings.py file ## This will redirect *all* Scrapy logs to your standard Python logging facility from twisted.python import log observer = log.PythonLoggingObserver() observer.start() # Snippet imported from snippets.scrapy.org (which no longer works) # author: saidimu # date : Jun 14, 2011