exceptions.AttributeError: '_SIGCHLDWaker' object has no attribute 'doWrite'
See original GitHub issueHello,
Thank your for your fantastic project. We are facing a really hard to solve bug while running scapy inside celery task. Sometimes we get this error:
Unhandled Error
Traceback (most recent call last):
File "/home/wirebot/.virtualenvs/cayzn_tracking.scraping/local/lib/python2.7/site-packages/twisted/python/log.py", line 101, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "/home/wirebot/.virtualenvs/cayzn_tracking.scraping/local/lib/python2.7/site-packages/twisted/python/log.py", line 84, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/home/wirebot/.virtualenvs/cayzn_tracking.scraping/local/lib/python2.7/site-packages/twisted/python/context.py", line 118, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/home/wirebot/.virtualenvs/cayzn_tracking.scraping/local/lib/python2.7/site-packages/twisted/python/context.py", line 81, in callWithContext
return func(*args,**kw)
--- <exception caught here> ---
File "/home/wirebot/.virtualenvs/cayzn_tracking.scraping/local/lib/python2.7/site-packages/twisted/internet/posixbase.py", line 602, in _doReadOrWrite
why = selectable.doWrite()
exceptions.AttributeError: '_SIGCHLDWaker' object has no attribute 'doWrite'
I think it’s related to a threading problem (I am not sure twisted is very thread safe) but maybe you already have an explanation ? Anyway, it seems bloated to run scrapy inside celery tasks because we need to recreate the crawler for each task, do you have any good advice on how to built a system to distribute crawls ? We are open to use scrapinghub but we have some very specific pipelines & download middlewares which prevent us to do so 😦
Issue Analytics
- State:
- Created 7 years ago
- Comments:6 (1 by maintainers)
Top Results From Across the Web
Why I am Getting '_SIGCHLDWaker' object has no attribute ...
doWrite () exceptions.AttributeError: '_SIGCHLDWaker' object has no attribute 'doWrite'. I am using: celery==3.1.19 Django==1.9.4 Scrapy==1.3.0.
Read more >[solved] Weird <type 'exceptions.AttributeError'> 'Row' object ...
Hi, just for other developers sake to save some time. I was getting this error: <type 'exceptions.AttributeError'> 'Row' object has no attribute 'id'....
Read more >Python Twisted Scrapy Attributeerror - ADocLib
I can't see any class exceptions.RuntimeError: AttributeError: UnixWaker instance has no attribute 'doWrite' 'SIGCHLDWaker' object has no attribute ...
Read more >AttributeError at / 'NoneType' object has no attribute 'strip', why ...
Coding example for the question AttributeError at / 'NoneType' object has no attribute 'strip', why and how? stuck here for a while-django.
Read more >Exceptions and common tracebacks - Plone Documentation
AttributeError : 'module' object has no attribute 'HTTPSConnection'¶. Python has not been compiled with HTTPS support. Try installing your Python, for example, ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I am still having issues at the moment. First I thought that it had to do with Python 3.8. I tried now with Python 3.7 and I still experience the same issues with Multiprocessing and ThreadPool.
Please get this fixed. 🙏
happen a similar problem with my project too. And I used the multiprocessing and apscheduler to manage various spiders.
I find a answer from stackoverflow, it say can replace reactor to asyncioreactor, and I heard reactor cannot restart in one process, maybe this is solution?
after do that, no more exception