uvloop is a fast, drop-in replacement of the built-in asyncio event loop. uvloop is implemented in Cython and uses libuv under the hood.
The project documentation can be found here. Please also check out the wiki.
Performance
uvloop makes asyncio 2-4x faster.
The above chart shows the performance of an echo server with different message sizes. The sockets benchmark uses loop.sock_recv() and loop.sock_sendall() methods; the streams benchmark uses asyncio high-level streams, created by the asyncio.start_server() function; and the protocol benchmark uses loop.create_server() with a simple echo protocol. Read more about uvloop performance.
Installation
uvloop requires Python 3.5 or greater and is available on PyPI. Use pip to install it:
$ pip install uvloop
Using uvloop
To make asyncio use uvloop, you can install the uvloop event loop policy:
import asyncio
import uvloop
asyncio.set_event_loop_policy(uvloop.EventLoopPolicy())
Building From Source
To build uvloop, you’ll need Python 3.5 or greater:
Clone the repository:
$ git clone --recursive git@github.com:MagicStack/uvloop.git $ cd uvloopCreate a virtual environment and activate it, for example:
$ python3.7 -m venv uvloop-dev $ source uvloop-dev/bin/activateInstall development dependencies:
$ pip install -r requirements.dev.txtBuild and run tests:
$ make && make test
License
uvloop is dual-licensed under MIT and Apache 2.0 licenses.
Metadata
Release files for uvloop 0.11.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| uvloop-0.11.3.tar.gz | 1.9 MB | Without provenance | Details for uvloop-0.11.3.tar.gz |
Built distributions (wheels)
Total release size: 28.2 MB
Release files / uvloop-0.11.3.tar.gz
| Download URL | uvloop-0.11.3.tar.gz |
|---|---|
| Size | 1.9 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fd5042d0a2ea07b92d0e2190f7711feb91cde31cf2bf1829e2e8c4c0fdd1f1aa
|
|
BLAKE2b-256 checksum How to use checksums |
46608e46188acba22369848d5e9bcbee3ca04b68a12d0598bd625c1a3994f5df
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Release files / uvloop-0.11.3-cp37-cp37m-manylinux1_x86_64.whl
| Download URL | uvloop-0.11.3-cp37-cp37m-manylinux1_x86_64.whl |
|---|---|
| Size | 3.7 MB |
| Tags | CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.5+ x86-64 |
|
SHA-256 checksum How to use checksums |
6549c9384a0256c97628f7a000b647e9496f7f8b211736f2e0b6858a738006bd
|
|
BLAKE2b-256 checksum How to use checksums |
627a01f8a6904deceb7b480ad3765dabb7f45b0e15510643799965dfc3cd944a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Release files / uvloop-0.11.3-cp37-cp37m-manylinux1_i686.whl
| Download URL | uvloop-0.11.3-cp37-cp37m-manylinux1_i686.whl |
|---|---|
| Size | 3.5 MB |
| Tags | CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.5+ x86-32 |
|
SHA-256 checksum How to use checksums |
48da0b548a341c1add4c7bc9dd453a9e9feb3b260c6055751fe6c209f957aeda
|
|
BLAKE2b-256 checksum How to use checksums |
c6a763d35cf23ebad1666775214bb728d98e605ca36138405ba06343ab4bc7f5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Release files / uvloop-0.11.3-cp37-cp37m-macosx_10_11_x86_64.whl
| Download URL | uvloop-0.11.3-cp37-cp37m-macosx_10_11_x86_64.whl |
|---|---|
| Size | 1.6 MB |
| Tags | CPython 3.7 CPython 3.7 pymalloc macOS 10.11+ x86-64 |
|
SHA-256 checksum How to use checksums |
708654c8e445f92160fc9e5c93387ca73f38904632527e5d38eb13eaa4fd0a12
|
|
BLAKE2b-256 checksum How to use checksums |
a3f57e440c8bae2be5cb7e79c41389f1d1d670da71fbca661438c0701f527599
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Release files / uvloop-0.11.3-cp36-cp36m-manylinux1_x86_64.whl
| Download URL | uvloop-0.11.3-cp36-cp36m-manylinux1_x86_64.whl |
|---|---|
| Size | 3.8 MB |
| Tags | CPython 3.6 CPython 3.6 pymalloc Linux glibc 2.5+ x86-64 |
|
SHA-256 checksum How to use checksums |
8f92c4ae4fcf497ca48e5d2f2032b1eabd48878b7a46b7748dfa8d607ef250b1
|
|
BLAKE2b-256 checksum How to use checksums |
5371154f98e003df68cbd95704c98cec1f2d09e271651f6232bafa1b2c2dc02f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Release files / uvloop-0.11.3-cp36-cp36m-manylinux1_i686.whl
| Download URL | uvloop-0.11.3-cp36-cp36m-manylinux1_i686.whl |
|---|---|
| Size | 3.5 MB |
| Tags | CPython 3.6 CPython 3.6 pymalloc Linux glibc 2.5+ x86-32 |
|
SHA-256 checksum How to use checksums |
8b53ed6d07b3aa8c8255d2f9fcaf7107cd4949c6892fa561472021ecec205764
|
|
BLAKE2b-256 checksum How to use checksums |
0fb674b45f52c702fd3357aabece67d012be22c911e7bfef87793ab167b885eb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Release files / uvloop-0.11.3-cp36-cp36m-macosx_10_11_x86_64.whl
| Download URL | uvloop-0.11.3-cp36-cp36m-macosx_10_11_x86_64.whl |
|---|---|
| Size | 1.6 MB |
| Tags | CPython 3.6 CPython 3.6 pymalloc macOS 10.11+ x86-64 |
|
SHA-256 checksum How to use checksums |
ab435a1ba78931ca8694a58478a7449b481c8442789e3420f31a593794c1c481
|
|
BLAKE2b-256 checksum How to use checksums |
6f7bba2262b6eafab6036cd1a686b6e005c727f2ff9e4485f4a766ee07f029dc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Release files / uvloop-0.11.3-cp35-cp35m-manylinux1_x86_64.whl
| Download URL | uvloop-0.11.3-cp35-cp35m-manylinux1_x86_64.whl |
|---|---|
| Size | 3.6 MB |
| Tags | CPython 3.5 CPython 3.5 pymalloc Linux glibc 2.5+ x86-64 |
|
SHA-256 checksum How to use checksums |
951331edad369cb9c000085e31da6bbb8af8ab791a726f7b29a608ccd79a6b74
|
|
BLAKE2b-256 checksum How to use checksums |
a31bce3e38f6d9b293aa64cbedf09aa09b55793fd7a2521c4e15323cb0ecfcab
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Release files / uvloop-0.11.3-cp35-cp35m-manylinux1_i686.whl
| Download URL | uvloop-0.11.3-cp35-cp35m-manylinux1_i686.whl |
|---|---|
| Size | 3.4 MB |
| Tags | CPython 3.5 CPython 3.5 pymalloc Linux glibc 2.5+ x86-32 |
|
SHA-256 checksum How to use checksums |
159331750bfce6f0f2bd227fd5e3ccb8db8d2bbe08e84b9db5b6c647f651f5c0
|
|
BLAKE2b-256 checksum How to use checksums |
24dd317b572333f27bc1dbb0851d26ff5f440947c465c78a825be1d046906ab4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Release files / uvloop-0.11.3-cp35-cp35m-macosx_10_11_x86_64.whl
| Download URL | uvloop-0.11.3-cp35-cp35m-macosx_10_11_x86_64.whl |
|---|---|
| Size | 1.6 MB |
| Tags | CPython 3.5 CPython 3.5 pymalloc macOS 10.11+ x86-64 |
|
SHA-256 checksum How to use checksums |
1cf6c111a19f782813ca57fa51a993978f4686de5e3ab5746bcd57af1a3ae4f8
|
|
BLAKE2b-256 checksum How to use checksums |
f2d8f5847b56e0e814d9dc648f5d015b00da680e7e95500a08a781e03f424606
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.5.6
|
Security for uvloop 0.11.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.