Re: threading.Semaphore or gevent.lock.Semaphore

2017-05-25 Thread dieter
ter response in a "Flask" mailing list. "gevent" is coroutine (not thread) based. This likely means that you should use "gevent" facilities for synchronisation - not the "threading" ones. > If I need semaphore, must I use threading.Semaph

threading.Semaphore or gevent.lock.Semaphore

2017-05-24 Thread Sergey
Hello, I'm developing Flask app, processed by gevent.wsgi.WSGIServer. If I need to isolate some pieces of code inside request handlers, can I use threading.Lock? If I need semaphore, must I use threading.Semaphore or gevent.lock.Semaphore? What is the difference between them? Than