[pypy-dev] Scrapy fails in PyPy

Joe Hillenbrand joehillen at gmail.com
Tue Dec 4 00:52:23 CET 2012


I've narrowed down the problem thanks to Amaury's suggestion.

It looks like it is caused by some black magic to figure out what arguments
a signal handler can accept.

https://github.com/scrapy/scrapy/blob/0.16/scrapy/xlib/pydispatch/robustapply.py

I haven't completely figured out what it is trying to do. It looks like it
is touching innards that PyPy might not have.

 It doesn't look like it is particularly well written anyway, so it will
probably need to be rewritten to be both CPython and PyPy compatible.


On Mon, Dec 3, 2012 at 10:01 AM, Armin Rigo <arigo at tunes.org> wrote:

> Hi,
>
> On Sun, Dec 2, 2012 at 4:09 PM, Joe Hillenbrand <joehillen at gmail.com>
> wrote:
> > (...)
> >         response=response, request=request, spider=spider)
> > (...)
> >         return receiver(*arguments, **named)
> >     exceptions.TypeError: response_received() got 4 unexpected keyword
> arguments
>
> No real clue, but it looks like keyword arguments are passed around as
> keyword arguments on PyPy, whereas CPython converts them to positional
> arguments somewhere along the call chain (which is long and goes via
> deferreds).  For us to help more, please provide a step-by-step "how
> to reproduce" list.  It's typically easy if we can reproduce the bug
> locally, and very hard if not.
>
>
> A bientôt,
>
> Armin.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pypy-dev/attachments/20121203/ce7f5a75/attachment.html>


More information about the pypy-dev mailing list