![](/img/trans.png)
[英]Exception gevent.hub.LoopExit: LoopExit('This operation would block forever',)
[英]Too many urls in greqests.map causes gevent.hub.LoopExit only on mac
我正在調用grequests.map
:
ret = grequests.map(rs, size=50)
使用rs
作為URL列表。 如果該列表的大小大於某個值(我的情況是300)我得到:
File "/Library/Python/2.7/site-packages/gevent/hub.py", line 331, in switch
return greenlet.switch(self)
gevent.hub.LoopExit: This operation would block forever
無論size
參數(我嘗試了10到50之間的不同值以及完全忽略這個參數)。
這只發生在macOS上。 在Ubuntu中,任何大小的URL列表都可以使用。
我會感激任何幫助,因為這是我的小型圖書館的一個showstopper。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.