Coroutine-based network library
Project description
gevent
gevent is a coroutine -based Python networking library that uses greenlet to provide a high-level synchronous API on top of the libev or libuv event loop.
Features include:
Lightweight execution units based on greenlets.
API that re-uses concepts from the Python standard library (for examples there are events and queues).
Cooperative DNS queries performed through a threadpool, dnspython, or c-ares.
Monkey patching utility to get 3rd party modules to become cooperative
TCP/UDP/HTTP servers
Subprocess support (through gevent.subprocess)
Thread pools
gevent is inspired by eventlet but features a more consistent API, simpler implementation and better performance. Read why others use gevent and check out the list of the open source projects based on gevent.
gevent was written by Denis Bilenko.
Since version 1.1, gevent is maintained by Jason Madden for NextThought with help from the contributors and is licensed under the MIT license.
See what’s new in the latest major release.
Check out the detailed changelog for this version.
Read the documentation online at http://www.gevent.org.
Post feedback and issues on the bug tracker, mailing list, blog and twitter (@gevent).
Installation and Requirements
Supported Platforms
gevent 1.5 runs on Python 2.7.9 and up, and Python 3.5, 3.6 and 3.7. gevent requires the greenlet library and will install the cffi library by default on Windows. The cffi library will become the default on all platforms in a future release of gevent.
gevent 1.5 also runs on PyPy 7.0 or above. On PyPy, there are no external dependencies.
gevent is tested on Windows, macOS, and Linux, and should run on most other Unix-like operating systems (e.g., FreeBSD, Solaris, etc.)
Older Versions of Python
Users of older versions of Python 2 or Python 3 may install an older version of gevent. Note that these versions are generally not supported.
Python Version |
Gevent Version |
---|---|
2.5 |
1.0.x |
2.6 |
1.1.x |
<= 2.7.8 |
1.2.x |
3.3 |
1.2.x |
3.4.0 - 3.4.2 |
1.3.x |
3.4.3 |
1.4.x |
Installation
gevent and greenlet can both be installed with pip, e.g., pip install gevent. Installation using buildout is also supported.
On Windows, macOS, and Linux, both gevent and greenlet are distributed as binary wheels.
Installing From Source
If you are unable to use the binary wheels (for platforms where no pre-built wheels are available or if wheel installation is disabled), you can build gevent from source. A normal pip install will fall back to doing this if no binary wheel is available. See Installing From Source for more, including common installation issues.
Extra Dependencies
gevent has no runtime dependencies outside the standard library, greenlet, and (on some platforms) cffi. However, there are a number of additional libraries that extend gevent’s functionality and will be used if they are available. All of these may be installed using setuptools extras, as named below, e.g., pip install gevent[events].
- events
Configurable event support using zope.event is highly recommended for configurable event support.
- dnspython
Enables the new pure-Python resolver, backed by dnspython. On Python 2, this also includes idna. They can be installed with the dnspython extra.
- monitor
Enhancements to gevent’s self-monitoring capabilities. This includes the psutil library which is needed to monitor memory usage. (Note that this may not build on all platforms.)
- recommended
A shortcut for installing suggested extras together.
- test
Everything needed to run the complete gevent test suite.
Development
For development information, including installing from git and running tests, see development.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for gevent-1.5a1-pp271-pypy_41-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 17a9686ed963c7f0d370bc096b0c91e19d99f2e04f65a5de2695577e1071d887 |
|
MD5 | 61aba9b752f15bb6ad24092babdc7fa8 |
|
BLAKE2b-256 | e01867b46f7d5bf21e0dab7762847dd49df3448bfd820dac234a6d9aaa0d4de7 |
Hashes for gevent-1.5a1-pp271-pypy_41-macosx_10_14_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 66f87af4894de2f2a739776737b47088770554003ddcf706ce8567d2e48a1c78 |
|
MD5 | 9ee1b2e3e5b573f4ae511c5b0e105d7f |
|
BLAKE2b-256 | 5fc81f8bd202b437a2ea3dc353a70577d6c9dc0277ee4992e17b97d0c1636fcf |
Hashes for gevent-1.5a1-cp37-cp37m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | df9c99c4e23e795f342b9bb489f209f569fb549095b7b3ca1b31bd2c6a2106d7 |
|
MD5 | 129e0104e32e4994e55cb09e1f42ef3e |
|
BLAKE2b-256 | 5d265275d4ccdbefed147122c3917f727aa870ddf6720467a98605af5052af1e |
Hashes for gevent-1.5a1-cp37-cp37m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0835990d528f1b613df99816b409d4916dee487e87289837375a49772e748a29 |
|
MD5 | c713911acf126d4e6436b124145f7cc0 |
|
BLAKE2b-256 | 6fa3c16bb15680776cb47567906e906239b6436f3f0ab28512ad2cab04fc650c |
Hashes for gevent-1.5a1-cp37-cp37m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 34d2d1dfade0f83f8938f69c981f1b281a8756d6cabcc60daa1ee3f3f1f1e5f2 |
|
MD5 | d2ef8465f4abe245f4d3aa4851a24ac1 |
|
BLAKE2b-256 | 3fb4c2acb758ae147c4320f3e0903afbc1031179e53740e2cf815f73ec51c898 |
Hashes for gevent-1.5a1-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9b324d004229e438f8c0cbe7617c06acaf6c9d9df400615249f39704d0fbb5c7 |
|
MD5 | d20d0a3eb7d57d5bed7d2f2b6cab7b9b |
|
BLAKE2b-256 | 1fb83003f41976c25569e672be3457ae84fcbd404a954e8ab1c356d8ef311735 |
Hashes for gevent-1.5a1-cp36-cp36m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 76d3a9575c86c3f6d865d2688adb6bf6eb43bb9dd90136224c746535137133eb |
|
MD5 | 1f145429b72143d3bb5fc5e4c320fe72 |
|
BLAKE2b-256 | 7ee567627cf3a476309d0cfdfae715440303f6d8dabcbaa43045b1f0f406fdc0 |
Hashes for gevent-1.5a1-cp36-cp36m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1acf2cb1b8c3c34f53397d7e5a1f883b1697fc5fd49789887583c3121332bdca |
|
MD5 | 36fcde6264486a8cd7c2a205eaff94ef |
|
BLAKE2b-256 | 6c834f1ad28242f4e2509a9ca3e6ad14a51e6f2b08604306081e9b8d91567e5a |
Hashes for gevent-1.5a1-cp36-cp36m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 09120f9c75af384f8ac65b8459e033fd99ab5fd665b3c01e3a2470c39c3cf60b |
|
MD5 | cc60df25193ab46fde9a72e0d30f698f |
|
BLAKE2b-256 | 51d8ca502e15462efb1e610d6b14d64882c106b125e9391f140ede44e3f8299b |
Hashes for gevent-1.5a1-cp36-cp36m-macosx_10_6_intel.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c59a7e837023db0b1c69a22820732d49f52cdb9a18c2d828cfce09f8dacd9f7d |
|
MD5 | 59799fde9c43dbdd47b618b39f7792cc |
|
BLAKE2b-256 | 220a438442871fbd6316fe4aac698126a51dc6bb7ec9d69ea50bc023483a9f47 |
Hashes for gevent-1.5a1-cp35-cp35m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6c08d260cae5b28d6a8d3a26e2a8759e65b1585877ce218f5140f465b0c6f846 |
|
MD5 | 9770539e1e7a475784eed2f86763f0f0 |
|
BLAKE2b-256 | 8f9f7be5d5df603149703065945a1dca2722b597f6a976ba206e3f6a8b46b721 |
Hashes for gevent-1.5a1-cp35-cp35m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c3afebb579423081b29a800d65838fe79292f7adf85e72f0734bd628bffbf624 |
|
MD5 | 1e0c175850dc68c75a7652d11d0c32c3 |
|
BLAKE2b-256 | 4e4b14a8e53ba4bd23f5db19ea5601f581f3f73f5aa8cbf1372dd66c8a479d27 |
Hashes for gevent-1.5a1-cp35-cp35m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 018677cd18b9e8f20d118fc425ffde9b7ce281aa39d66a9b689153bfaa40661d |
|
MD5 | 322386993ff857e33facd0c7124a9184 |
|
BLAKE2b-256 | 44ee10359d65496b117683503856c9e03a0c9d485e98d59f81ef53baa6890c4c |
Hashes for gevent-1.5a1-cp35-cp35m-macosx_10_6_intel.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b3b17b3e41d7f531d30d1461deccb346bba7a54f09a7f4a1686abf6c2731acb6 |
|
MD5 | 78da8c3e91d13bc9649d393c5326c854 |
|
BLAKE2b-256 | c7d03bad267dd983c28944d2f08093d7b79b350a94485707300032200217218a |
Hashes for gevent-1.5a1-cp27-cp27mu-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | de2bed77aca19ad915293a916c67cff8eb36e3616828d91e2ed4cc16f1d9f967 |
|
MD5 | cc13c348cc9444453975c78acb6b9563 |
|
BLAKE2b-256 | 8214e945d1f8b6179a1959ec7a479b655c7021a3d580b49106ea56864c50e4c8 |
Hashes for gevent-1.5a1-cp27-cp27m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 80a6da1437e3b6afe197477bbf80c7d0a6efa3265f99c3064e2a17d811485a9f |
|
MD5 | 5b7c84a336ac77c2d20ba413b8dcefa8 |
|
BLAKE2b-256 | 93afcf044a586e925f78d6f99cee178100d7b878bff69e79b45111e62f2e3acb |
Hashes for gevent-1.5a1-cp27-cp27m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0bd38a07e723f5a7feea267a3cf7a19db65583552b5d2960050df1208e396f2b |
|
MD5 | 6b458e318efcbb0bfb83e15d939c646e |
|
BLAKE2b-256 | 20e3a1b255d5f40cba7b141fb50ef8eaa575ed449f22b4990799ec50196544ab |
Hashes for gevent-1.5a1-cp27-cp27m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8fa234dadacf8e1920c088bd7ee2220a2a5e45f098b6f603995bb3e4bb27877a |
|
MD5 | b042b09e5142c1a8abaaaa0ae10f53db |
|
BLAKE2b-256 | 187be6c7d7b634c22d96a1e4bb55900fc1c7587388fea47aac62963feeab7ff1 |
Hashes for gevent-1.5a1-cp27-cp27m-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 63d9deb376144836e760207c2d7cd009b3b6a2e01f3634dcfc07d9d3b396cfe4 |
|
MD5 | ff1ad3b0904aa39bf39986f4f8c9feb4 |
|
BLAKE2b-256 | 878a6a7ffe79f2cce4b64f2f31a9be2dbfd32ccb06868ad94013c5594302d36c |