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
This version of gevent runs on Python 2.7.9 and up, and Python 3.5, 3.6, 3.7 and 3.8. 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.
This version of gevent 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.
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-20.5.0-pp27-pypy_73-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 38db524ea88d81d596b2cbb6948fced26654a15fec40ea4529224e239a6f45e8 |
|
MD5 | aa93507d0cff9cf82d7a10a866697091 |
|
BLAKE2b-256 | 90c1c6e8649da2d8692ed0f629986629ca6c51a09ba9d18f8c2faa8b29e168b8 |
Hashes for gevent-20.5.0-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 28b7d83b4327ceb79668eca2049bf4b9ce66d5ace18a88335e3035b573f889fd |
|
MD5 | ca2a5f95f5fe839457efa10b5adca800 |
|
BLAKE2b-256 | d9e6cd1f647490d56ca358b47c0d61eca1a8fe01c8b9aa7bef8c58598fcf1414 |
Hashes for gevent-20.5.0-cp38-cp38-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d07a2afe4215731eb57d5b257a2e7e7e170d8a7ae1f02f6d0682cd3403debea9 |
|
MD5 | dc9271c521684f2d14443bd38abc4615 |
|
BLAKE2b-256 | 68556e57562028e21b0a96ecea3a0f0ba1e37c1c1daa57e452d2bac256e0e784 |
Hashes for gevent-20.5.0-cp38-cp38-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 88c76df4967c5229f853aa67ad1b394d9e4f985b0359c9bc9879416bba3e7c68 |
|
MD5 | bcc4f5555d0bc6bed8a05fa1ff960b3d |
|
BLAKE2b-256 | ceac5faeac66d2827bda496ac88c0c1a253a3a709cd71a1ae2b62d697223e100 |
Hashes for gevent-20.5.0-cp38-cp38-macosx_10_14_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5c604179cebcc57f10505d8db177b92a715907815a464b066e7eba322d1c33ac |
|
MD5 | a50fd24ce49aecf4d4411aedc011bda1 |
|
BLAKE2b-256 | 327b3434ff9f4338ab7dc489addae61bb4cbdc5866979e51ab0a0f7fb9378862 |
Hashes for gevent-20.5.0-cp37-cp37m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a7805934e8ce81610b61f806572c3d504cedd698cc8c9460d78d2893ba598c4a |
|
MD5 | 99a051d69befc28a5290dd59afb61262 |
|
BLAKE2b-256 | 9f917a87e67d16939b86508badfb6c8636a30fba7aa24793030d886007e94c3a |
Hashes for gevent-20.5.0-cp37-cp37m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0acc15ba2ac2a555529ad82d5a28fc85dbb6b2ff947657d67bebfd352e2b5c14 |
|
MD5 | cedea85998564035525e1def0a872e61 |
|
BLAKE2b-256 | c0690d16e0f1a114a31a38679c81ffa52181ea67579ab543516a0eda6b1cc1e5 |
Hashes for gevent-20.5.0-cp37-cp37m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 31dc5d4ab8172cc00c4ff17cb18edee633babd961f64bf54214244d769bc3a74 |
|
MD5 | bdcd197a7c0ce9af98aba547e76c8983 |
|
BLAKE2b-256 | 0b5585c758c389a3c84f999b445e423b6b148227f03104fa7957e84179d9a97b |
Hashes for gevent-20.5.0-cp37-cp37m-macosx_10_14_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e01d5373528e4ebdde66dc47a608d225fa3c4408ccd828d26c49b7ff75d82bd9 |
|
MD5 | 314fc0da598c970f8941cf9f7196f482 |
|
BLAKE2b-256 | 744675df26768e846f0129f8ac6b25f36ee6514cc115c27c8a328b25d35e4b44 |
Hashes for gevent-20.5.0-cp36-cp36m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9b4e940fc6071afebb86ba5f48dbb5f1fc3cb96ebeb8cf145eb5b499e9c6ee33 |
|
MD5 | d05fcfb6f8dbd58231e3913c540c986f |
|
BLAKE2b-256 | 9bd2406247fe0cbb89c63acf892c1c0c065f291128e217e5ddc07318a8ae0cc8 |
Hashes for gevent-20.5.0-cp36-cp36m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 15eae3cd450dac7dae7f4ac59e01db1378965c9ef565c39c5ae78c5a888f9ac9 |
|
MD5 | 730b01230ecdb82b99f90ee7b0d3df6b |
|
BLAKE2b-256 | bf4782befa8eeed1c675eecf668cc1cad216f8515645e81791f9875d1505eccf |
Hashes for gevent-20.5.0-cp36-cp36m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 52e5cd607749ed3b8aa0272cacf2c11deec61fca4c3bec57a9fea8c49316627d |
|
MD5 | 064174bda465ae3e3f375c962c84f424 |
|
BLAKE2b-256 | 9ebd04c4036f46f0272c804fce2c8308e06f8fb5db3b5c3adf97f8765bfa502c |
Hashes for gevent-20.5.0-cp36-cp36m-macosx_10_14_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 929c33df8e9bcbe31906024fcd21580bd018196dbd3249eb5b2f19d63e11092d |
|
MD5 | 01c99a6413c2ef0870e75ee453b9035a |
|
BLAKE2b-256 | c675d1efef071532153263f57b63610e0d8578548cdfb2b38a05ba5262d3a850 |
Hashes for gevent-20.5.0-cp35-cp35m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 937d36730f2b0dee3387712074b1f15b802e2e074a3d7c6dcaf70521236d607c |
|
MD5 | 74caaefb2e1673388bb43e9723f61deb |
|
BLAKE2b-256 | 42c2363d96c0ae2f1826d8ac128bc67572bc97a84767eae947eff3557ecef4ab |
Hashes for gevent-20.5.0-cp35-cp35m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 00b03601b8dd1ee2aa07811cb60a4befe36173b15d91c6e207e37f8d77dd6fac |
|
MD5 | b39abef3114a64555c54391e11b27942 |
|
BLAKE2b-256 | f22c43c4783bc9d7f512a081307d6a26c98f06dded92cd4d76f4ca571d1ad5d7 |
Hashes for gevent-20.5.0-cp35-cp35m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4d2729dd4bf9c4d0f29482f53cdf9fc90a498aebb5cd7ae8b45d35657437d2ac |
|
MD5 | 6db2024cf48d15025210cf0bd8191f8a |
|
BLAKE2b-256 | 732e6991b4a9b1e3239f3283005d81286c36eff937871f4796d28c37ea571a61 |
Hashes for gevent-20.5.0-cp27-cp27mu-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fcb64f3a28420d1b872b7ef41b12e8a1a4dcadfc8eff3c09993ab0cdf52584a1 |
|
MD5 | b7e955b7b25669cde611ec82bfdce6fe |
|
BLAKE2b-256 | 2210a67b79e3a5f98dbb65efbc236c7d65e46cd7d93ec20f5366556ac0f6b3a9 |
Hashes for gevent-20.5.0-cp27-cp27m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1dd95433be45e1115053878366e3f5332ae99c39cb345be23851327c062b9f4a |
|
MD5 | f8e100be7f257e18e235f95830e4b0be |
|
BLAKE2b-256 | 97608224bffdfd34674a0ec830bb579775b7cb62ba46aa9b2510203c654969ce |
Hashes for gevent-20.5.0-cp27-cp27m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 92edc18a357473e01a4e4a82c073ed3c99ceca6e3ce93c23668dd4a2401f07dc |
|
MD5 | 6860f143bba21bd0e36ed35f008f070f |
|
BLAKE2b-256 | 3fa383ec87f92fa03170249ae177116d1fc8c7c17d0d2075710a2a4498f33686 |
Hashes for gevent-20.5.0-cp27-cp27m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3ff477b6d275396123faf8ce2d5b82f96d85ba264e0b9d4b56a2bac49d1b9adc |
|
MD5 | bca35081c7e81cea370928ce52af06b8 |
|
BLAKE2b-256 | 3161debeb3a517f4d0f8b7c383a7924ac91510048b3cf42dc270593159a7c0e3 |
Hashes for gevent-20.5.0-cp27-cp27m-macosx_10_14_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | efd9546468502a30ddd4699c3124ccb9d3099130f9b5ae1e2a54ad5b46e86120 |
|
MD5 | 1dea1751afe65b28310f66c8f23e5588 |
|
BLAKE2b-256 | 40729cd23e4c988d621bbf409bbe016294da481de9e94a8909f9224719c9b0c7 |