-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add process_spider_output_async() to the spider middleware. #91
base: master
Are you sure you want to change the base?
Conversation
I believe you can install a newer version of the entrypoint through |
@@ -1,5 +1,6 @@ | |||
# -*- coding: utf-8 -*- | |||
import itertools | |||
from warnings import warn |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is for the call in HubstorageDownloaderMiddleware.from_crawler()
, added in some older change.
@@ -28,11 +29,22 @@ def process_spider_output(self, response, result, spider): | |||
parent = self._seen_requests.pop(response.request, None) | |||
for x in result: | |||
if isinstance(x, Request): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check not extracted because we tentatively decided that as a general pattern for such middlewares we prefer to separate "process_request" and "process_item" logic.
I confirmed this works (if the project has an async middleware, there is a warning normally and no warning if this branch is installed explicitly). |
Fixes #72.
I wonder how can we test the change on Scrapy Cloud before merging this though?