Skip to main content

An async Curl library.

Project description

Acurl

It is an asynchronous wrapper around libcurl which is built to interface with the Uvloop python library.

Using Acurl In Mite

The gateway into Acurl is through the CurlWrapper (discussed in Architectural Notes) and requires an event loop being passed to its constructor. Below is the mite implementation of acurl:

class SessionPool:
    ...
    def __init__(self):
        import acurl
        self._wrapper = acurl.CurlWrapper(asyncio.get_event_loop())
        ...

Architectural Notes

Acurl uses a single loop maintained within python using UVloop.

Acurl surfaces the CurlWrapper interface which takes the asyncio event loop as an argument. The wrapper deals directly with the curl_multi interface from libcurl, defining 2 functions (curl_perform_write and curl_perform_read) for checking both read and write availability of file descriptors.

There are 2 notable functions within the core Acurl implementation, notably handle_socket and start_timer:

  • handle_socket is passed as a callback function to the curl_multi interface and upon calls to the curl_multi_socket_action function, will receive updates regarding the socket status. We then handle those statuses by either adding or removing the aforementioned readers or writers.
  • start_timer is another callback function that is passed to the curl_multi interface and is used as a way to handle timeouts and retries within curl. Upon a timeout, the timeout callback will be called and the transfer can be retried.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

acurl-1.0.2.tar.gz (167.6 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

acurl-1.0.2-pp39-pypy39_pp73-macosx_10_9_x86_64.whl (89.2 kB view details)

Uploaded PyPymacOS 10.9+ x86-64

acurl-1.0.2-pp38-pypy38_pp73-macosx_10_9_x86_64.whl (88.9 kB view details)

Uploaded PyPymacOS 10.9+ x86-64

acurl-1.0.2-pp37-pypy37_pp73-macosx_10_9_x86_64.whl (89.1 kB view details)

Uploaded PyPymacOS 10.9+ x86-64

acurl-1.0.2-cp310-cp310-musllinux_1_1_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.10musllinux: musl 1.1+ x86-64

acurl-1.0.2-cp310-cp310-macosx_11_0_arm64.whl (110.2 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

acurl-1.0.2-cp310-cp310-macosx_10_9_x86_64.whl (126.1 kB view details)

Uploaded CPython 3.10macOS 10.9+ x86-64

acurl-1.0.2-cp39-cp39-musllinux_1_1_x86_64.whl (2.5 MB view details)

Uploaded CPython 3.9musllinux: musl 1.1+ x86-64

acurl-1.0.2-cp39-cp39-macosx_11_0_arm64.whl (112.4 kB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

acurl-1.0.2-cp39-cp39-macosx_10_9_x86_64.whl (128.6 kB view details)

Uploaded CPython 3.9macOS 10.9+ x86-64

acurl-1.0.2-cp38-cp38-musllinux_1_1_x86_64.whl (2.5 MB view details)

Uploaded CPython 3.8musllinux: musl 1.1+ x86-64

acurl-1.0.2-cp38-cp38-macosx_11_0_arm64.whl (111.2 kB view details)

Uploaded CPython 3.8macOS 11.0+ ARM64

acurl-1.0.2-cp38-cp38-macosx_10_9_x86_64.whl (125.1 kB view details)

Uploaded CPython 3.8macOS 10.9+ x86-64

acurl-1.0.2-cp37-cp37m-musllinux_1_1_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.7mmusllinux: musl 1.1+ x86-64

acurl-1.0.2-cp37-cp37m-macosx_10_9_x86_64.whl (122.1 kB view details)

Uploaded CPython 3.7mmacOS 10.9+ x86-64

acurl-1.0.2-cp36-cp36m-musllinux_1_1_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.6mmusllinux: musl 1.1+ x86-64

acurl-1.0.2-cp36-cp36m-macosx_10_9_x86_64.whl (122.7 kB view details)

Uploaded CPython 3.6mmacOS 10.9+ x86-64

File details

Details for the file acurl-1.0.2.tar.gz.

File metadata

  • Download URL: acurl-1.0.2.tar.gz
  • Upload date:
  • Size: 167.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.8

File hashes

Hashes for acurl-1.0.2.tar.gz
Algorithm Hash digest
SHA256 f6d6f22c8c3cac6c93ce0b61afe3b7a3ffa5f1a16f270c9fa64fec217a6e0da5
MD5 a0e226675a466fc4e86463fb22791417
BLAKE2b-256 cf48707dfd423024ea1cc04d3f41b53ec68f6f33fe2fb6cc094be8b08bdc2f8e

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-pp39-pypy39_pp73-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-pp39-pypy39_pp73-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 2ad2ebac7ac4230adb99c2363100c8da0d7a21d7821d8222f2b62076309b6607
MD5 57188ab5cff445a457329551c92f2d85
BLAKE2b-256 46752449d9106f36f3c6f612b104e8260909766ac2d19c8f720daf5f0ecff8fd

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-pp38-pypy38_pp73-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-pp38-pypy38_pp73-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 9ee855546829f3fc1004ab8f45b48a3a136fbcdb519cc9981f30c28dd0a5c5ae
MD5 ebc46825b240e9cd47cc6000a7ac1c07
BLAKE2b-256 94986a764ed893f5c32e1650497e62f708dc2292100d84e73f83341e3e909a01

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-pp37-pypy37_pp73-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-pp37-pypy37_pp73-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 9f625f64d84c7ba0d8c70011e09a486c34f6033878c27ff969302f25fd1f237c
MD5 50a299931515bc9f4d7254fafd75a3d3
BLAKE2b-256 206c8e0570826e61cf40533519ccdc02b3d5b09b2aa85b2aa56fddb9bb69bd77

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp310-cp310-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp310-cp310-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 03e31cb3d52c4b94889a1db6900e512cf8bb17f3930477e3060f3e0f6f23df6f
MD5 40d0d9b2163dc8f2a11c0e234f374b0a
BLAKE2b-256 3e9e0b562b55ebe9f1d5678f005014ffbe686841e936c6346c7d20ae95b2dbab

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 2e8e7356f64721f4a4bbf363665715279de3a99e6d4548a5dc932cfeeca84342
MD5 b8dfc9376122ea51c101549d157f9b1f
BLAKE2b-256 0f0c737a1d1d241fafc91830785744d864dbb5444dd7305b3803a85d3ff9f959

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp310-cp310-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 73442b7d6d557c38e0b2a9217d5fee832fe799911c60a50721999972b77f2206
MD5 b0de94786c1d3aa2e6f115452bd53dee
BLAKE2b-256 9b4471fdc3f4deb709ba676d0e3d8f608817128efff68f1d1234dec9bf7c3077

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp39-cp39-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp39-cp39-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 b0f843b5ed6835aae5458e21b7eb18d19fd96f1592e035d394ad211e04e1b2d5
MD5 dfc0df129a8cb6efc6818776e32c484a
BLAKE2b-256 4894dd48068ec00e8d585bbea451981d3a97a8506108f58550c828af10d798a0

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

  • Download URL: acurl-1.0.2-cp39-cp39-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 112.4 kB
  • Tags: CPython 3.9, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.5

File hashes

Hashes for acurl-1.0.2-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 1a6037635727716b8d9352f8b382d19dae2e2af6a6eec1926b5491222aab20c7
MD5 8821bb39864be13ff0be6d84ad75efd5
BLAKE2b-256 096e678e4a11331dc8b2164b87be09be165cd4c604fb0a4fe6a13e1248fd3c43

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp39-cp39-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 bb972c294323e062f59a22106a095858dec7ee6fb2de12de2395501445888ddb
MD5 40e41536da56a2544f1dfa95a54581ad
BLAKE2b-256 f8330378580ee185b6131f157c857bae358ed0e9ab0c967084d4474a7a7514eb

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp38-cp38-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp38-cp38-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 87ebc4c62325b35ad5da600e9689afaacfdf28a3d6a9d20f691e5df418cbe1e9
MD5 f3aad7e71fab2ca6fd3800c8d726ad85
BLAKE2b-256 fe557525be79f47d9d93689500bca27fb36343669f83f242024e1933f98cd17c

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp38-cp38-macosx_11_0_arm64.whl.

File metadata

  • Download URL: acurl-1.0.2-cp38-cp38-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 111.2 kB
  • Tags: CPython 3.8, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.5

File hashes

Hashes for acurl-1.0.2-cp38-cp38-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 eda8bc9968ce2223acfa24a6e0d34f7d45a556cbb5da41dffeef74888be71956
MD5 cd94cf223c2a0932419a19ea972fbc4d
BLAKE2b-256 145f40c3bc0a5583f3bef7c69efa7c841500b0663ce1fbb19267a7ba0f574159

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp38-cp38-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 58c4ce7e3a7325ee7360485ba490f3b6766c0f2c1d14a5d6ab059988f36198ff
MD5 821060ffcbf953c7208df5661e36d317
BLAKE2b-256 a804e5c4018e0196befc7f7368f62652f748f052669c7b69acdaf32856419786

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp37-cp37m-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp37-cp37m-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 23c70cd151d4e62851cdf793146e97032d74b65bebfd7f52c4d6575c72241aeb
MD5 3d12395d3d8537f11050c95f8ecbde43
BLAKE2b-256 576819046d3e8d89d4ea705d7a784e02ce52d93fa922df4283b7be3c0ea9c999

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp37-cp37m-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 13cf4327b73db2a767685e30f47945adefe0767eb1151ca66d661539f07aab26
MD5 9db37e9a832024031ce2de80cab63e47
BLAKE2b-256 be1aa9cffd777a6dc11d196c548ed6fd8cff37db429ab299645b3238b024dbb3

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp36-cp36m-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp36-cp36m-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 8badda552f9ac97b1f332c99e7189a5b0d869d43faf77a43f40a03ebd5cf58b9
MD5 2bb2146b89693c56ac69277d882a717a
BLAKE2b-256 6bd08b012d1cd5cf3226edb55fba36ab0061fb324ece654d0e0520d75e821e22

See more details on using hashes here.

File details

Details for the file acurl-1.0.2-cp36-cp36m-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for acurl-1.0.2-cp36-cp36m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 61cc968118c1ad27a48900bf9de27138e9e1772636c9f96937a7fe50fcb599ef
MD5 7818b22252c56b6022b10c9cbb47c3fb
BLAKE2b-256 adf8119abd9647279f5e191899f963754bec257fe07905768658d24877c2f40c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page