databases
databases copied to clipboard
Async database support for Python. 🗄
I've got some tables that use JSON fields, and would like to query their contents. The fields have a variable structure, and might contain either arrays or dicts. However, I...
OS: Debian 10 Buster Python: 3.9 Databases: 0.5.3 Database backend: postgresql/asyncpg There was an issue with our database and our app was hanging. We received this asyncpg warning: > Pool.close()...
Closes #413
**OS**: macOS Monterey, 12.0.1 (M1 Pro) **python version**: Python 3.7 **databases version**: 0.5.5 **database backend (mysql, sqlite or postgresql)**: sqlite **database driver (aiopg, aiomysql etc.)**: aiosqlite I'm trying to use...
**Current behavior** When connection to the database is dropped (e.g. due to Kubernetes Pod restart), the program freezes. This only seems to manifest when wrapped in a transaction. **Expected behavior**...
A valid DSN with two hosts eg: `postgresql://user:password@host1:port1,host2:port2/db?...` which is a valid postgres DSN format (https://www.postgresql.org/docs/10/libpq-connect.html) cannot be used with databases because of `urlsplit` parsing exception for port. Pure `asyncpg`...
## Background In sqlite3, if you set `uri=True` you can pass query param arguments to the underlying database, including: - `mode = memory, ro, rw` - `cache = shared` Examples:...
Are there any strategies to use a mock during testing that work with `databases`?
Resolves https://github.com/encode/databases/issues/460
``` ... my code await database.execute(query) File "/usr/local/lib/python3.10/site-packages/databases/core.py", line 169, in execute async with self.connection() as connection: File "/usr/local/lib/python3.10/site-packages/databases/core.py", line 256, in __aenter__ raise e File "/usr/local/lib/python3.10/site-packages/databases/core.py", line 253, in...