Peewee v2.4.5 Release Notes
-
๐ I'm excited about this release, as in addition to a number of new features and bugfixes, it also is a step towards cleaner code. I refactored the tests into a number of modules, using a standard set of base test-cases and helpers. I also introduced the
mock
library into the test suite and plan to use it for cleaner tests going forward. There's a lot of work to do to continue cleaning up the tests, but I'm feeling good about the changes. Curiously, the test suite runs faster now.๐ Bugs fixed
- #471, #482 and #484, all of which had to do with how joins were handled by the
aggregate_rows()
query result wrapper. - ๐ #472 removed some needless special-casing in
Model.save()
. - ๐ #466 fixed case-sensitive issues with the SQLite migrator.
- ๐ #474 fixed a handful of bugs that cropped up migrating foreign keys with SQLite.
- ๐ #475 fixed the behavior of the SQLite migrator regarding auto-generated indexes.
- ๐ #479 fixed a bug in the code that stripped extra parentheses in the SQL generator.
- ๐ Fixed a handful of bugs in the APSW extension.
๐ New features
- โ Added connection abstraction called
ExecutionContext
(see docs). - Made all context managers work as decorators (
atomic
,transaction
,savepoint
,execution_context
). - โ Added explicit methods for
IS NULL
andIS NOT NULL
queries. The latter was actually necessary since the behavior is different fromNOT IS NULL (...)
. - ๐ Allow disabling backref validation (#465)
- ๐ Made quite a few improvements to the documentation, particularly sections on transactions.
- โ Added caching to the DataSet extension, which should improve performance.
- Made the SQLite migrator smarter with regards to preserving indexes when a table copy is necessary.
- #471, #482 and #484, all of which had to do with how joins were handled by the