OpenDAL Python Binding
Project description
OpenDAL Python Binding
Documentation: main
This crate intends to build a native python binding.
Installation
pip install opendal
Usage
import opendal
op = opendal.Operator("fs", root="/tmp")
op.write("test.txt", b"Hello World")
print(op.read("test.txt"))
print(op.stat("test.txt").content_length)
Or using the async API:
import asyncio
async def main():
op = opendal.AsyncOperator("fs", root="/tmp")
await op.write("test.txt", b"Hello World")
print(await op.read("test.txt"))
asyncio.run(main())
Development
Setup virtualenv:
python -m venv venv
Activate venv:
source venv/bin/activate
Install maturin
:
pip install maturin[patchelf]
Build bindings:
maturin develop
Run some tests:
maturin develop -E test
behave tests
Build API docs:
maturin develop -E docs
pdoc opendal
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
opendal-0.41.0.tar.gz
(524.1 kB
view hashes)
Built Distributions
Close
Hashes for opendal-0.41.0-cp37-abi3-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ba5abec90218220a41d64d910114f4864d11593be3f51475f37cb67c9b5e4a03 |
|
MD5 | 15b21d7b54af3d20f066c76235d2d791 |
|
BLAKE2b-256 | faedb8bd7b15ca4828405ea1f226641ff0e13880a5a14eb436a031124bfb81d9 |
Close
Hashes for opendal-0.41.0-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 314c1cb4140aa9b6da32c9e0a193247628dbd7ebcda427a709bafbbbc1351f0c |
|
MD5 | bcc5b22af82a6cc648cac9afea0065a4 |
|
BLAKE2b-256 | c79f6e64495916ee61a5622c10f7a479556395501c5765ebc8efa24450d7f6d2 |
Close
Hashes for opendal-0.41.0-cp37-abi3-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | db45b4915ad275f40aa27de2413299fcaf07fec7f77b7f8ab2f98e81a9298c3c |
|
MD5 | a690d9bd7461c1759588efb6085cafa5 |
|
BLAKE2b-256 | ed999abda91f8afef5070b35017dfaa611c0d7cddd6f2eea2d866261df1410fb |