Skip to main content

Asynchronous file IO for Linux MacOS or Windows.

Project description

Python wrapper for AIO

NOTE: Native Linux aio implementation supports since 4.18 kernel version.

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())

Troubleshooting

The linux implementation works normal for modern linux kernel versions and file systems. So you may have problems specific for your environment. It's not a bug and might be resolved some ways:

  1. Upgrade the kernel
  2. Use compatible file system
  3. Use threads based or pure python implementation.

The caio since version 0.7.0 contains some ways to do this.

  1. In runtime use the environment variable CAIO_IMPL with possible values:
    • linux - use native linux kernels aio mechanism
    • thread - use thread based implementation written in C
    • python - use pure python implementation
  2. File default_implementation located near __init__.py in caio installation path. It's useful for distros package maintainers. This file might contains comments (lines starts with # symbol) and the first line should be one of linux thread or python.

Previous versions allows direct import of the target implementation.

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.9.25.tar.gz (26.8 kB view details)

Uploaded Source

Built Distributions

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

caio-0.9.25-py3-none-any.whl (19.1 kB view details)

Uploaded Python 3

caio-0.9.25-cp314-cp314-manylinux_2_34_x86_64.whl (80.1 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.34+ x86-64

caio-0.9.25-cp314-cp314-manylinux_2_34_aarch64.whl (81.6 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.34+ ARM64

caio-0.9.25-cp314-cp314-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl (81.8 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.12+ x86-64manylinux: glibc 2.17+ x86-64

caio-0.9.25-cp314-cp314-macosx_10_15_universal2.whl (37.0 kB view details)

Uploaded CPython 3.14macOS 10.15+ universal2 (ARM64, x86-64)

caio-0.9.25-cp313-cp313-manylinux_2_34_x86_64.whl (80.2 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.34+ x86-64

caio-0.9.25-cp313-cp313-manylinux_2_34_aarch64.whl (81.5 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.34+ ARM64

caio-0.9.25-cp313-cp313-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl (81.9 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.12+ x86-64manylinux: glibc 2.17+ x86-64

caio-0.9.25-cp313-cp313-macosx_10_13_universal2.whl (37.0 kB view details)

Uploaded CPython 3.13macOS 10.13+ universal2 (ARM64, x86-64)

caio-0.9.25-cp312-cp312-manylinux_2_34_x86_64.whl (80.2 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.34+ x86-64

caio-0.9.25-cp312-cp312-manylinux_2_34_aarch64.whl (81.5 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.34+ ARM64

caio-0.9.25-cp312-cp312-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl (82.0 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.12+ x86-64manylinux: glibc 2.17+ x86-64

caio-0.9.25-cp312-cp312-macosx_10_13_universal2.whl (37.0 kB view details)

Uploaded CPython 3.12macOS 10.13+ universal2 (ARM64, x86-64)

caio-0.9.25-cp311-cp311-manylinux_2_34_x86_64.whl (78.3 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.34+ x86-64

caio-0.9.25-cp311-cp311-manylinux_2_34_aarch64.whl (80.1 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.34+ ARM64

caio-0.9.25-cp311-cp311-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl (80.3 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.12+ x86-64manylinux: glibc 2.17+ x86-64

caio-0.9.25-cp311-cp311-macosx_10_9_universal2.whl (36.8 kB view details)

Uploaded CPython 3.11macOS 10.9+ universal2 (ARM64, x86-64)

caio-0.9.25-cp310-cp310-manylinux_2_34_x86_64.whl (77.7 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.34+ x86-64

caio-0.9.25-cp310-cp310-manylinux_2_34_aarch64.whl (79.5 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.34+ ARM64

caio-0.9.25-cp310-cp310-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl (79.7 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.12+ x86-64manylinux: glibc 2.17+ x86-64

caio-0.9.25-cp310-cp310-macosx_10_9_universal2.whl (36.8 kB view details)

Uploaded CPython 3.10macOS 10.9+ universal2 (ARM64, x86-64)

File details

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

File metadata

  • Download URL: caio-0.9.25.tar.gz
  • Upload date:
  • Size: 26.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.25

File hashes

Hashes for caio-0.9.25.tar.gz
Algorithm Hash digest
SHA256 16498e7f81d1d0f5a4c0ad3f2540e65fe25691376e0a5bd367f558067113ed10
MD5 e48f0055de6e5cc29980fc5506d3da1f
BLAKE2b-256 9288b8527e1b00c1811db339a1df8bd1ae49d146fcea9d6a5c40e3a80aaeb38d

See more details on using hashes here.

File details

Details for the file caio-0.9.25-py3-none-any.whl.

File metadata

  • Download URL: caio-0.9.25-py3-none-any.whl
  • Upload date:
  • Size: 19.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for caio-0.9.25-py3-none-any.whl
Algorithm Hash digest
SHA256 06c0bb02d6b929119b1cfbe1ca403c768b2013a369e2db46bfa2a5761cf82e40
MD5 421f1d860fdef8b583e4dc98885cdb38
BLAKE2b-256 86931f76c8d1bafe3b0614e06b2195784a3765bbf7b0a067661af9e2dd47fc33

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp314-cp314-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp314-cp314-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 0ba16aa605ccb174665357fc729cf500679c2d94d5f1458a6f0d5ca48f2060a7
MD5 0c967b7ea896e56dafd9c938f2df8de5
BLAKE2b-256 3fedbf81aeac1d290017e5e5ac3e880fd56ee15e50a6d0353986799d1bc5cfd5

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp314-cp314-manylinux_2_34_x86_64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp314-cp314-manylinux_2_34_aarch64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp314-cp314-manylinux_2_34_aarch64.whl
Algorithm Hash digest
SHA256 628a630eb7fb22381dd8e3c8ab7f59e854b9c806639811fc3f4310c6bd711d79
MD5 6f945712eb5ce5336c339bc6849c56a5
BLAKE2b-256 87a4e534cf7d2d0e8d880e25dd61e8d921ffcfe15bd696734589826f5a2df727

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp314-cp314-manylinux_2_34_aarch64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp314-cp314-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp314-cp314-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 44a6b58e52d488c75cfaa5ecaa404b2b41cc965e6c417e03251e868ecd5b6d77
MD5 53c91d95f15e6b41b6d6e06aff64f520
BLAKE2b-256 5e6cd4d24f65e690213c097174d26eda6831f45f4734d9d036d81790a27e7b78

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp314-cp314-macosx_10_15_universal2.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp314-cp314-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 fab6078b9348e883c80a5e14b382e6ad6aabbc4429ca034e76e730cf464269db
MD5 c8dce8bf2688a28bc43926e53fd2a05a
BLAKE2b-256 69caa08fdc7efdcc24e6a6131a93c85be1f204d41c58f474c42b0670af8c016b

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp313-cp313-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp313-cp313-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 9ed3cfb28c0e99fec5e208c934e5c157d0866aa9c32aa4dc5e9b6034af6286b7
MD5 29105e397f7652a24ffafdfe405ec4b6
BLAKE2b-256 2259f8f2e950eb4f1a5a3883e198dca514b9d475415cb6cd7b78b9213a0dd45a

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp313-cp313-manylinux_2_34_x86_64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp313-cp313-manylinux_2_34_aarch64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp313-cp313-manylinux_2_34_aarch64.whl
Algorithm Hash digest
SHA256 1a177d4777141b96f175fe2c37a3d96dec7911ed9ad5f02bac38aaa1c936611f
MD5 60a21bf82067d709784f40570806b194
BLAKE2b-256 9c12c39ae2a4037cb10ad5eb3578eb4d5f8c1a2575c62bba675f3406b7ef0824

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp313-cp313-manylinux_2_34_aarch64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp313-cp313-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp313-cp313-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 0998210a4d5cd5cb565b32ccfe4e53d67303f868a76f212e002a8554692870e6
MD5 900c2ea22dc96eb17c91b2624bb58a6b
BLAKE2b-256 a39ff21af50e72117eb528c422d4276cbac11fb941b1b812b182e0a9c70d19c5

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp313-cp313-macosx_10_13_universal2.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp313-cp313-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 d6c2a3411af97762a2b03840c3cec2f7f728921ff8adda53d7ea2315a8563451
MD5 16f69aca2e889ba4a08b1d8a54b30bab
BLAKE2b-256 31575e6ff127e6f62c9f15d989560435c642144aa4210882f9494204bc892305

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp312-cp312-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp312-cp312-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 6bebf6f079f1341d19f7386db9b8b1f07e8cc15ae13bfdaff573371ba0575d69
MD5 44e4830ce383e26e183477a1ba205f88
BLAKE2b-256 d11c0fe770b8ffc8362c48134d1592d653a81a3d8748d764bec33864db36319d

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp312-cp312-manylinux_2_34_x86_64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp312-cp312-manylinux_2_34_aarch64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp312-cp312-manylinux_2_34_aarch64.whl
Algorithm Hash digest
SHA256 4fa69eba47e0f041b9d4f336e2ad40740681c43e686b18b191b6c5f4c5544bfb
MD5 9758409008c09aa6e8a285f2ccdfee01
BLAKE2b-256 03c48a1b580875303500a9c12b9e0af58cb82e47f5bcf888c2457742a138273c

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp312-cp312-manylinux_2_34_aarch64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp312-cp312-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp312-cp312-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 97084e4e30dfa598449d874c4d8e0c8d5ea17d2f752ef5e48e150ff9d240cd64
MD5 c3049d18c998d74158bb52ec74bf561e
BLAKE2b-256 a32b21288691f16d479945968a0a4f2856818c1c5be56881d51d4dac9b255d26

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp312-cp312-macosx_10_13_universal2.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp312-cp312-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 fb7ff95af4c31ad3f03179149aab61097a71fd85e05f89b4786de0359dffd044
MD5 a1fcafe2b2662edf4b83ba2fb0e0dade
BLAKE2b-256 d32579c98ebe12df31548ba4eaf44db11b7cad6b3e7b4203718335620939083c

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp311-cp311-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp311-cp311-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 fc220b8533dcf0f238a6b1a4a937f92024c71e7b10b5a2dfc1c73604a25709bc
MD5 e0a353ffece49c9191e792d9aed41f41
BLAKE2b-256 4690e278863c47e14ec58309aa2e38a45882fbe67b4cc29ec9bc8f65852d3e45

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp311-cp311-manylinux_2_34_x86_64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp311-cp311-manylinux_2_34_aarch64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp311-cp311-manylinux_2_34_aarch64.whl
Algorithm Hash digest
SHA256 ae3d62587332bce600f861a8de6256b1014d6485cfd25d68c15caf1611dd1f7c
MD5 60b61b45db01f90fd4e0fee1d36ae674
BLAKE2b-256 dfce65e64867d928e6aff1b4f0e12dba0ef6d5bf412c240dc1df9d421ac10573

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp311-cp311-manylinux_2_34_aarch64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp311-cp311-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp311-cp311-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 bf84bfa039f25ad91f4f52944452a5f6f405e8afab4d445450978cd6241d1478
MD5 74c20988776cc36e8167e4ee79ea6fcf
BLAKE2b-256 513b36f3e8ec38dafe8de4831decd2e44c69303d2a3892d16ceda42afed44e1b

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp311-cp311-macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp311-cp311-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 d6956d9e4a27021c8bd6c9677f3a59eb1d820cc32d0343cea7961a03b1371965
MD5 5d255fee34f819e1083e5d60683de236
BLAKE2b-256 ec90543f556fcfcfa270713eef906b6352ab048e1e557afec12925c991dc93c2

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp310-cp310-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp310-cp310-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 ab52e5b643f8bbd64a0605d9412796cd3464cb8ca88593b13e95a0f0b10508ae
MD5 7723a44943c3c9276b75af6563b8fb19
BLAKE2b-256 8895dd55757bb671eb4c376e006c04e83beb413486821f517792ea603ef216e9

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp310-cp310-manylinux_2_34_x86_64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp310-cp310-manylinux_2_34_aarch64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp310-cp310-manylinux_2_34_aarch64.whl
Algorithm Hash digest
SHA256 bf61d7d0c4fd10ffdd98ca47f7e8db4d7408e74649ffaf4bef40b029ada3c21b
MD5 eba0bc71fb9368e28ce24882c1376e58
BLAKE2b-256 0bab07080ecb1adb55a02cbd8ec0126aa8e43af343ffabb6a71125b42670e9a1

See more details on using hashes here.

Provenance

The following attestation bundles were made for caio-0.9.25-cp310-cp310-manylinux_2_34_aarch64.whl:

Publisher: publish.yml on mosquito/caio

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file caio-0.9.25-cp310-cp310-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp310-cp310-manylinux2010_x86_64.manylinux2014_x86_64.manylinux_2_12_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 db9b5681e4af8176159f0d6598e73b2279bb661e718c7ac23342c550bd78c241
MD5 17b89432c941facf34f49b2515260a13
BLAKE2b-256 17b936715c97c873649d1029001578f901b50250916295e3dddf20c865438865

See more details on using hashes here.

File details

Details for the file caio-0.9.25-cp310-cp310-macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for caio-0.9.25-cp310-cp310-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 ca6c8ecda611478b6016cb94d23fd3eb7124852b985bdec7ecaad9f3116b9619
MD5 33fbfd64914f8b88feb354523d16b28e
BLAKE2b-256 6a80ea4ead0c5d52a9828692e7df20f0eafe8d26e671ce4883a0a146bb91049e

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