Why gevent.monkey.patch_all does not patch Queue.Queue?

158 views
Skip to first unread message

Phus Lu

unread,
Jan 31, 2012, 3:36:41 AM1/31/12
to gevent: coroutine-based Python network library
Hi list,

when i read gevent/monkey.py, I'm puzzled that why `patch_all`
function does not patch Queue.Queue. As we known, many socket based
libs: like pymongo/pycassa, use Queue.Queue implement the `connection
pool`. so I'm not sure that if i patch Queue.Queue witch
gevent.queue.Queue, will it bring some bug?
Thank you!

Phus

Matt Joiner

unread,
Feb 3, 2012, 3:46:20 AM2/3/12
to gev...@googlegroups.com

It doesn't need to. Queue uses Condition, which uses RLock, which uses Lock which is already patched.

Reply all
Reply to author
Forward
0 new messages