Release Notes¶
0.11.3¶
Fixed¶
- Excessive and confusing debug logging for overwrite selection.
- Allow
DATABASEZ_POLL_INTERVALoverwrites.
0.11.2¶
Fixed¶
- Ruff calls were using different rulesets.
- Cleaned up
database_exist,drop_database,create_databasemethods of DatabaseTestClient. - Remove dependency on sqlalchemy_utils.
- Provide get_quoter for retrieving a quote method.
0.11.1¶
Fixed¶
- Python 3.9 compatibility.
0.11.0¶
Added¶
- Add support for jdbc reflection.
0.10.3¶
Fixed¶
- The global connection is now entered lazily despite sub-databases.
- Fix deadlock with full_isolation off.
- Fix database.transaction() failing because of AsyncDatabaseHelper.
- Fix DatabaseTestClient not able to use config initialization.
0.10.2¶
Fixed¶
- Fix transactions in multi-threading contexts.
Changed¶
- The transaction stack contains the backend too.
Removed¶
- Remove
ACTIVE_TRANSACTIONSContextVar plus tests for it. It became unreliable with multithreading.
0.10.1¶
Added¶
poll_intervalparameter (only relevant when using multithreading).
Fixed¶
- Improved thread-safety.
- full_isolation was not passed through in TestClient.
0.10.0¶
Added¶
full_isolationparameter. Isolate the force_rollback Connection in a thread.- Timeouts for operations.
Fixed¶
batched_iterateinterface ofConnectiondiffered from the one ofDatabase.iterateinterface ofConnectiondiffered from the one ofDatabase.- Hooks were called on automatically created Database objects.
- More multithreading safety.
0.9.7¶
Added¶
- It is now possible to use connect(), disconnect() instead of a async contextmanager in multi-loop calls (multithreading).
Fixed¶
- Database calls are forwarded to subdatabase when possible. This unbreaks using not the returned database object.
force_rollbackworks also in multi-loop call (multithreading).
0.9.6¶
Fixed¶
- Databasez is now threadsafe (and multiloop safe).
0.9.5¶
Changed¶
- Extract more options by default from query options.
Fixed¶
disconnect_hookwas called too early.connect_hookwas called too late.posnot passed through in fetch_one.
0.9.4¶
Changed¶
- Implement iterate in sqlalchemy base class (before it was a forward to batched_iterate).
Fixed¶
- iterate and batched_iterate misconfigure connection.
0.9.3¶
Added¶
- Add lazy_setup parameter for testclient.
disconnectandconnectreturn if they performed the setup/cleanup.- Add backward compatible overwrites of defaults to the TestClient.
Fixed¶
- Restore eager setup behavior in testclient.
- Fix drop_dabase with postgresql.
- Fix setup/disconnect hangups.
- Fix ancient docs deps.
Removed¶
- Dependency on nest_asyncio. It is an archived repo.
0.9.2¶
Added¶
- Expose customization hooks for disconnects, connects.
Fixed¶
- Testclient has issues with missing permissions.
- Lazy global connection.
0.9.1¶
Added¶
- Expose customization hooks for execute result parsing for subclasses of sqlalchemy.
Fixed¶
execute_manyworks now efficient and properly and returns autoincrement column ids.executereturned not autoincrement id but defaults.
0.9.0¶
Added¶
force_rollbackis now a descriptor returning an extensive ForceRollback object.- Setting True, False, None is now possible for overwriting the value/resetting to the initial value (None).
- Deleting it resets it to the initial value.
- Its trueness value evaluates to the current value, context-sensitive.
- It still can be used as a contextmanager for temporary overwrites.
Fixed¶
- Fixed refcount for global connections.
Changed¶
connect/disconnectcalls are now refcounted. Nesting is now supported.- ACTIVE_TRANSACTIONS dict is not replaced anymore when initialized.
0.8.5¶
Added¶
- Allow overwriting
force_rollbackwhen copying via passing Database as parameter.
Changed¶
- The
force_rollbackparameter is now None by default.
Fixed¶
- Fix typo in Testclient copying path.
0.8.4¶
Added¶
- Provide
__copy__method for Database, DatabaseBackend. - Database is now an allowed type for Database (used for copying). Same is true for the DatabaseTestClient subclass.
Fixed¶
- Speed of tests.
- DATABASE_CONFIG_URLS had passwords not properly unquoted.
0.8.3¶
Added¶
- DatabaseTestClient has now an option for changing the test prefix.
Fixed¶
- DatabaseTestClient can now use the improvements in 0.8.0 too.
- DatabaseTestClient is now tested.
- Fix run_sync on Database objects.
0.8.2¶
Fixed¶
- Cannot pass parameters to execute directly. Bulk_inserts not possible anymore.
0.8.1¶
Fixed¶
- The
dbapi2dialect used only a single thread for all connections. - Some options were not translated into query options and vice versa.
0.8.0¶
Added¶
batched_iterate.jdbcdialect to load nearly all jdbc drivers (note: many features won't work).dbapi2dialect to load nearly all dbapi2 drivers (note: many features won't work).
Changed¶
- Use psycopg3 by default. Autoupgrade
postgres://topostgres+psycopg://. Note: this behavior differs from sqlalchemy which still uses psycopg2 by default. fetch_alluses now iterate as fallback.hatchis now used for release management, cleaning.- Use mariadb for tests instead of mysql (resource problems).
Removed¶
aiopgsupport (no update for 2 years and better alternatives available).- Remove Makefile and other scripts.
- Own
run_syncimplementation. Use asyncio.run instead.
Fixed¶
docker composedoesn't uses that much resources anymore.
0.7.2¶
Fixed¶
- Regression introduced by asyncio with
DatabaseTestClient.
0.7.1¶
Fixed¶
- Fix regression introduced by SQLAlchemy 2.0.25 with
make_url.
0.7.0¶
Fixed¶
urllib.parse.urlsplitwas causing the password or username from being properly parsed and split with special characters.
0.6.0¶
Added¶
- Support for Python 3.12
Changed¶
pyodbcversion for MSSQL driver.
0.5.0¶
Fixed¶
- Patch done in the core of Databases fixing the concurrent usage of connections and transactions. This patch also affects databases. #PR 546 by @zevisert. We thank @zevisert for the fix done in the original project that also affect Databasez.
0.4.0¶
Changed¶
- Added extra support for unix sockets for mysql and asyncmy. PR #13 by tarsil.
- Update version of SQLAlchemy.
0.3.0¶
Changed¶
- Upgraded SQLAlchemy to version 2.0.12+ where the BaseRow implementation was redesigned and improved in terms of performance. #10
- Updated internal Record representation of the returned Row from SQLAlchemy reflecting the performance improvements.
0.2.2¶
Fixed¶
- Bad state when a connection was cancelled.
0.2.1¶
Fixed¶
- Error raised when checking the column mapping for empty columns.
0.2.0¶
Changed¶
- Updated requirements to the latest of sqlalchemy and added support for
nest_asyncio.
Added¶
- New
run_syncfunction for connections allowing every connection to run blocking operations inside async. For example, asqlalchemy inspect
0.1.0¶
Initial release.
This is the official release of databasez where it provides the experience as the one
forked from Encode with additional features and improvements.
- SQLAlchemy 2+ integration.
- Additonal support for
mssql. - Connection as dict.
- Brings a native test client.