Async I/O for CouchDB built on aiohttp
This project is based on the (seemingly) unmaintained aiocoucdb but is not a drop-in replacement for that project.
Example
Using aiocouchdb3 is pretty easy.
import aiocouchdb3 as couchdb
user_jwt = get_user_jwt()
async with couchdb.connect() as client:
async with client.with_token(user_jwt) as session:
for db in await session.all_dbs:
print(await db.info)
Features
- Allows authentication for both username/password and JWT
Contribute
Thanks for considering adding your skills to improve this library.
Please review the Contributor Covenant Code of Conduct.
You must comply with it to contribute to aiocouchdb3.
Set up your local development environment
Check .python-version for the minimum version
of Python supported by aiocouchdb3. Install that and use it to create a
Poetry environment.
Install dependencies with
poetry install --all-extras
You must provide both mocked and integration tests when contributing. Get a CouchDB v3 instance up and running. (If you use Docker, see the following section about using Docker to run a properly configured CouchDB v3 instance.)
Running tests
There are two kinds of tests in the project found the ./tests directory.
-
./tests/mockedcontain proper unit tests isolated from the execution environment. -
./tests/integrationcontain integration tests that rely on a running instance of CouchDB. To run these copy./test.envto./.test.envand provide values for the two empty keys in it (and modify the other two if you want to).# Copy this file to .test.env and provide values for your # instance of CouchDB COUCHDB_USER = COUCHDB_PASSWORD = COUCHDB_DB_BASE_URL = http://locahost:5984 COUCHDB_JWT_SECRET = devsecret
There's a Docker compose file in
testsavailable for you to use if you want to use that.docker compose --env-file .test.env -f tests/docker-compose/docker-compose.yaml up
Run the tests with
poetry run pytest
If you want to run the tests while you're developing
poetry run ptw .
Metadata
Release files for aiocouchdb3 0.1.5
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 |
|---|---|---|---|---|
| aiocouchdb3-0.1.5.tar.gz | 10.2 kB | Without provenance | Details for aiocouchdb3-0.1.5.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| aiocouchdb3-0.1.5-py3-none-any.whl | Python 3 | none | any | Details for aiocouchdb3-0.1.5-py3-none-any.whl |
Total release size: 19.7 kB
Release files / aiocouchdb3-0.1.5.tar.gz
| Download URL | aiocouchdb3-0.1.5.tar.gz |
|---|---|
| Size | 10.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d5cdfaafee86c81d3cf83866dba60410919bd4763bd4604e1b7c222f0e4ce5db
|
|
BLAKE2b-256 checksum How to use checksums |
3c7b3d44790c92120688b7e576079e83e63b560dff83880a6d4e8be5c7f93c59
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
poetry/2.1.3 CPython/3.13.5 Linux/5.15.154+
|
Release files / aiocouchdb3-0.1.5-py3-none-any.whl
| Download URL | aiocouchdb3-0.1.5-py3-none-any.whl |
|---|---|
| Size | 9.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e82564f34f2a396d6d68b7a6655c1689e0cc5f37ffba054a0f4688564c04236d
|
|
BLAKE2b-256 checksum How to use checksums |
7b5b5f1e5a86321ee42d676ea0fd0186483ea195262b3222c1ba86a559e28bd5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
poetry/2.1.3 CPython/3.13.5 Linux/5.15.154+
|
Security for aiocouchdb3 0.1.5
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.