Skip to main content

Asynchronous file IO for Linux Posix and Windows.

Project description

Python bindings for Linux AIO API and simple asyncio wrapper.

Example

import asyncio
from caio import AsyncioContext

loop = asyncio.get_event_loop()

async def main():
    # max_requests=128 by default
    ctx = AsyncioContext(max_requests=128)

    with open("test.file", "wb+") as fp:
        fd = fp.fileno()

        # Execute one write operation
        await ctx.write(b"Hello world", fd, offset=0)

        # Execute one read operation
        print(await ctx.read(32, fd, offset=0))

        # Execute one fdsync operation
        await ctx.fdsync(fd)

        op1 = ctx.write(b"Hello from ", fd, offset=0)
        op2 = ctx.write(b"async world", fd, offset=11)

        await asyncio.gather(op1, op2)

        print(await ctx.read(32, fd, offset=0))
        # Hello from async world


loop.run_until_complete(main())

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

caio-0.6.2.tar.gz (18.5 kB view details)

Uploaded Source

Built Distributions

caio-0.6.2-cp39-cp39-manylinux2010_x86_64.whl (81.9 kB view details)

Uploaded CPython 3.9 manylinux: glibc 2.12+ x86-64

caio-0.6.2-cp39-cp39-macosx_10_9_x86_64.whl (32.6 kB view details)

Uploaded CPython 3.9 macOS 10.9+ x86-64

caio-0.6.2-cp38-cp38-manylinux2010_x86_64.whl (107.3 kB view details)

Uploaded CPython 3.8 manylinux: glibc 2.12+ x86-64

caio-0.6.2-cp38-cp38-macosx_10_9_x86_64.whl (42.5 kB view details)

Uploaded CPython 3.8 macOS 10.9+ x86-64

caio-0.6.2-cp37-cp37m-manylinux2010_x86_64.whl (82.4 kB view details)

Uploaded CPython 3.7m manylinux: glibc 2.12+ x86-64

caio-0.6.2-cp37-cp37m-macosx_10_9_x86_64.whl (32.4 kB view details)

Uploaded CPython 3.7m macOS 10.9+ x86-64

caio-0.6.2-cp36-cp36m-manylinux2010_x86_64.whl (80.7 kB view details)

Uploaded CPython 3.6m manylinux: glibc 2.12+ x86-64

caio-0.6.2-cp36-cp36m-macosx_10_9_x86_64.whl (32.4 kB view details)

Uploaded CPython 3.6m macOS 10.9+ x86-64

caio-0.6.2-cp35-cp35m-manylinux2010_x86_64.whl (80.2 kB view details)

Uploaded CPython 3.5m manylinux: glibc 2.12+ x86-64

caio-0.6.2-cp35-cp35m-macosx_10_6_intel.whl (38.0 kB view details)

Uploaded CPython 3.5m macOS 10.6+ intel

File details

Details for the file caio-0.6.2.tar.gz.

File metadata

  • Download URL: caio-0.6.2.tar.gz
  • Upload date:
  • Size: 18.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2.tar.gz
Algorithm Hash digest
SHA256 7180f9b5fec51116da5f5044ecdaa0d005481f4bc333b832b48a16eae0664d41
MD5 85230c2d8fdacf2c39db741b45429ccf
BLAKE2b-256 e2f4f82904b6141f7d2c79571b84321478af13edae11a4f77eb5d49e422fcbf4

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp39-cp39-manylinux2010_x86_64.whl.

File metadata

  • Download URL: caio-0.6.2-cp39-cp39-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 81.9 kB
  • Tags: CPython 3.9, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp39-cp39-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 d6da75ccc1a1e6ddf4a052db5dc35299280b323827b97eff5522fc09d87247e6
MD5 7f6e6fd09cda0296ff3c2319f22ee9e5
BLAKE2b-256 7ff2b75a7e70bb702ec0811c1fcbd85147fe10cdfb1de1ea732cbaf81b3d591a

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp39-cp39-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: caio-0.6.2-cp39-cp39-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 32.6 kB
  • Tags: CPython 3.9, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 e99a44192c7b3e58e131b5f0d7fe73b22aa2213b8adcd889a41c6a5253060a65
MD5 235c5e5bd1c34162edaea9cd815a8c0d
BLAKE2b-256 deb07b2b5aba682318c92c8e198e98eca7e4f154d9970ca112f657608a9b2bdf

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp38-cp38-manylinux2010_x86_64.whl.

File metadata

  • Download URL: caio-0.6.2-cp38-cp38-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 107.3 kB
  • Tags: CPython 3.8, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp38-cp38-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 fd5aeeb7aa584ac6555db1e36c077c7df866df110a2ef48f870c97d0d9beb387
MD5 4b7380b113b0beba33fe5a531c4e4e64
BLAKE2b-256 f96a53fc0d0ddc743a40d9a1d51c9b31dad56ed246d404f3f333f1440576c853

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp38-cp38-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: caio-0.6.2-cp38-cp38-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 42.5 kB
  • Tags: CPython 3.8, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 7cc942997b300c2418cd4bfcb6f6d150d1a6d830c5013e804ee5730d0a8eaf8e
MD5 203e420d4a7419c4a845d3585e229f6f
BLAKE2b-256 01035ef44603a81c5ebb81a1e01d91f055041bd4d70b1c0aed90508ce3435519

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp37-cp37m-manylinux2010_x86_64.whl.

File metadata

  • Download URL: caio-0.6.2-cp37-cp37m-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 82.4 kB
  • Tags: CPython 3.7m, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp37-cp37m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 b056934106491b0b61ea70adf66702a3fa4a863b713f0b7ed68cf0b60f6160c4
MD5 ee67b224d8276da4c6626bfeacc33b3f
BLAKE2b-256 398af0908745f591f9622cd6a3418eebae08010fe8b254e243406937cebf0856

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp37-cp37m-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: caio-0.6.2-cp37-cp37m-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 32.4 kB
  • Tags: CPython 3.7m, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 654ce616fdc9e46b60b8335ea1d54858d331e828394ca9761954e37b1c255c45
MD5 d46f6f25588365dc84fcfb4e74cdd12b
BLAKE2b-256 0183f6feceea9c39863041f284f178f948b9136eb05ae57f876f61ec7de0720d

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp36-cp36m-manylinux2010_x86_64.whl.

File metadata

  • Download URL: caio-0.6.2-cp36-cp36m-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 80.7 kB
  • Tags: CPython 3.6m, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp36-cp36m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 0dae3d8092fefb2fa6f7f3576d5ce4d6214d2967ea09f0af288ddfdaf5fd5980
MD5 d9ae407f3bede7940f4080ca88d27027
BLAKE2b-256 fb96a50872273ffac81955af389ececcf047da3071d2874fedb76c14145b4269

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp36-cp36m-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: caio-0.6.2-cp36-cp36m-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 32.4 kB
  • Tags: CPython 3.6m, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp36-cp36m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 7399236687a311e4e07cc4ef692d7af70d1808171ac6ee14b7b9a1cbcc7b4e6d
MD5 e7791dfa66b1495e1fa222b7d6253000
BLAKE2b-256 95e25fa1cad7e5fa17fdb3c4e78a35aca4e63446af1b5ba882cb533d129fc647

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp35-cp35m-manylinux2010_x86_64.whl.

File metadata

  • Download URL: caio-0.6.2-cp35-cp35m-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 80.2 kB
  • Tags: CPython 3.5m, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp35-cp35m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 311b38632b4e800ae95734bb8c61eecb84e72f70cce4a4357e93d73a36910300
MD5 c85427651a1d3aafa2f9f8c6974b4f1b
BLAKE2b-256 66f94ca53d7d70b0964fb754aa91076e86d4580427a7ac7a38c5a73ea2b3a9df

See more details on using hashes here.

File details

Details for the file caio-0.6.2-cp35-cp35m-macosx_10_6_intel.whl.

File metadata

  • Download URL: caio-0.6.2-cp35-cp35m-macosx_10_6_intel.whl
  • Upload date:
  • Size: 38.0 kB
  • Tags: CPython 3.5m, macOS 10.6+ intel
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3

File hashes

Hashes for caio-0.6.2-cp35-cp35m-macosx_10_6_intel.whl
Algorithm Hash digest
SHA256 95220e7307afe9cd9002ac1e5ee7b8acde6457adbcc5d6b415f17325cd7757bc
MD5 78afa2da0f7f1fef5a5fc0030ec6c637
BLAKE2b-256 49b4685e73cfa7f63450f0a26eee3ba4e8c6aa51d51e324e7a6691fed03a3037

See more details on using hashes here.

Supported by

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