pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/databases/py-peewee py-peewee: updated to 3.10.0

branches:  trunk
changeset: 337426:4a123cfcf73a
user:      adam <>
date:      Mon Aug 05 07:56:42 2019 +0000

py-peewee: updated to 3.10.0


Add a helper to playhouse.mysql_ext for creating Match full-text search expressions.
Added date-part properties to TimestampField for accessing the year, month, day, etc., within a SQL expression.
Added to_timestamp() helper for DateField and DateTimeField that produces an expression returning a unix timestamp.
Add autoconnect parameter to Database classes. This parameter defaults to True and is compatible with previous versions of Peewee, in which executing a query on a closed database would open a 
connection automatically. To make it easier to catch inconsistent use of the database connection, this behavior can now be disabled by specifying autoconnect=False, making an explicit call to 
Database.connect() needed before executing a query.
Added database-agnostic interface for obtaining a random value.
Allow isolation_level to be specified when initializing a Postgres db.
Allow hybrid properties to be used on model aliases.
Support aggregates with FILTER predicates on the latest Sqlite.

More aggressively slot row values into the appropriate field when building objects from the database cursor (rather than using whatever cursor.description tells us, which is buggy in older Sqlite).
Be more permissive in what we accept in the insert_many() and insert() methods.
When implicitly joining a model with multiple foreign-keys, choose the foreign-key whose name matches that of the related model. Previously, this would have raised a ValueError stating that multiple 
FKs existed.
Improved date truncation logic for Sqlite and MySQL to make more compatible with Postgres' date_trunc() behavior. Previously, truncating a datetime to month resolution would return '2019-08' for 
example. As of 3.10.0, the Sqlite and MySQL date_trunc implementation returns a full datetime, e.g. '2019-08-01 00:00:00'.
Apply slightly different logic for casting JSON values with Postgres. Previously, Peewee just wrapped the value in the psycopg2 Json() helper. In this version, Peewee now dumps the json to a string 
and applies an explicit cast to the underlying JSON data-type (e.g. json or jsonb).

Bug fixes
Save hooks can now be called for models without a primary key.
Fixed bug in the conversion of Python values to JSON when using Postgres.
Fix for differentiating empty values from NULL values in model_to_dict.
Fixed a bug referencing primary-key values that required some kind of conversion (e.g., a UUID).
Add small jitter to the pool connection timestamp to avoid issues when multiple connections are checked-out at the same exact time.


 databases/py-peewee/Makefile |   4 ++--
 databases/py-peewee/distinfo |  10 +++++-----
 2 files changed, 7 insertions(+), 7 deletions(-)

diffs (28 lines):

diff -r e7770f6b9734 -r 4a123cfcf73a databases/py-peewee/Makefile
--- a/databases/py-peewee/Makefile      Sun Aug 04 21:05:34 2019 +0000
+++ b/databases/py-peewee/Makefile      Mon Aug 05 07:56:42 2019 +0000
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.58 2019/06/10 07:36:14 adam Exp $
+# $NetBSD: Makefile,v 1.59 2019/08/05 07:56:42 adam Exp $
-DISTNAME=      peewee-3.9.6
+DISTNAME=      peewee-3.10.0
 CATEGORIES=    databases python
diff -r e7770f6b9734 -r 4a123cfcf73a databases/py-peewee/distinfo
--- a/databases/py-peewee/distinfo      Sun Aug 04 21:05:34 2019 +0000
+++ b/databases/py-peewee/distinfo      Mon Aug 05 07:56:42 2019 +0000
@@ -1,7 +1,7 @@
-$NetBSD: distinfo,v 1.51 2019/06/10 07:36:14 adam Exp $
+$NetBSD: distinfo,v 1.52 2019/08/05 07:56:42 adam Exp $
-SHA1 (peewee-3.9.6.tar.gz) = 5ed2665aad77e9a355cea0c8df8de4ab9c12d00c
-RMD160 (peewee-3.9.6.tar.gz) = 214e503e5dca4651f9bdb279953fa391f2fe7e5e
-SHA512 (peewee-3.9.6.tar.gz) = 6413a893bb4f19c537c3c622c00d29715ea9e635b527d50bdbd3f87d1f7f59a8408af7a9f5f3729701550c3b72346c5563dacf5e8e9b39ca46713bf2cda0d0ad
-Size (peewee-3.9.6.tar.gz) = 810586 bytes
+SHA1 (peewee-3.10.0.tar.gz) = 1f0f3be7b2469d694c0f1f60ca7c2ed6102fb621
+RMD160 (peewee-3.10.0.tar.gz) = 6699b96096aa1a644ddeaa0284114a4a76a83852
+SHA512 (peewee-3.10.0.tar.gz) = 0ff8a465cf9624313d8326f872dc42238b5eb6ee0ccc06504dcf5491ade34592f49562bbcf7b0f9cf69dff5e703e938c917cea2bc0859f5e32f98921a9a5a498
+Size (peewee-3.10.0.tar.gz) = 2275148 bytes
 SHA1 ( = 2d4d9fde18df606b584dffe04aa9da22de3e4dcc

Home | Main Index | Thread Index | Old Index