[MRG+1] fix a mistake in topic spider-middleware.rst #3201
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3201 +/- ##
=======================================
Coverage 82.12% 82.12%
=======================================
Files 228 228
Lines 9593 9593
Branches 1385 1385
=======================================
Hits 7878 7878
Misses 1456 1456
Partials 259 259 |
This fix looks consistent with the docs,
and
Although this is not checked in the code |
Hi, @lopuhin I have written several middlewares just about this method, |
@grammy-jiang I agree - I think your fix is good and should be merged, I was just wondering what will happen if a response is returned. |
@lopuhin Emmm... good point. In my view, the method So your question becomes what happens when a response yielded from a spider? I have no idea, no relative experience before... |
Right, returning a response from a spider looks very strange indeed! |
@lopuhin I have checked the class So will there any type assert in engine or scheduler? I am not good enough at twisted, would you help to check? Thanks. |
The return iterable of
process_spider_exception
should containscrapy.http.Request
, notscrapy.http.Response
.