From 5ed45d21a437edfb88292050c0c65a45b75f21dc Mon Sep 17 00:00:00 2001 From: Alexander Kozlovsky Date: Mon, 21 Jan 2019 10:09:38 +0300 Subject: [PATCH] Fix reading NULL from optional nullable array column --- pony/orm/dbapiprovider.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pony/orm/dbapiprovider.py b/pony/orm/dbapiprovider.py index 378f3bff4..50caac12d 100644 --- a/pony/orm/dbapiprovider.py +++ b/pony/orm/dbapiprovider.py @@ -846,7 +846,7 @@ def validate(converter, val, obj=None): return TrackedArray(obj, converter.attr, items) def dbval2val(converter, dbval, obj=None): - if obj is None: + if obj is None or dbval is None: return dbval return TrackedArray(obj, converter.attr, dbval)