From 528364c51b27a9e5666ddd4ca3e1d47721bff2e3 Mon Sep 17 00:00:00 2001 From: Praneeth Bedapudi Date: Mon, 30 Oct 2023 22:19:29 +0530 Subject: [PATCH] return all keys irrespective of Null Signed-off-by: Praneeth Bedapudi --- liteindex/defined_index.py | 4 ++-- setup.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/liteindex/defined_index.py b/liteindex/defined_index.py index fed9fe4..b61c040 100644 --- a/liteindex/defined_index.py +++ b/liteindex/defined_index.py @@ -287,7 +287,6 @@ def get(self, ids, select_keys=[]): record = { self.key_hash_to_original_key[h]: val for h, val in zip(select_keys, row[1:]) - if val is not None } for k, v in record.items(): if v is None: @@ -365,9 +364,10 @@ def search( record = { self.key_hash_to_original_key[h]: val for h, val in zip(self.original_key_to_key_hash.values(), result[2:]) - if val is not None } for k, v in record.items(): + if v is None: + continue if self.schema[k] == "other": record[k] = pickle.loads(v) elif self.schema[k] == "datetime": diff --git a/setup.py b/setup.py index 16bbc19..79d6743 100644 --- a/setup.py +++ b/setup.py @@ -18,7 +18,7 @@ EMAIL = "praneeth@bpraneeth.com" AUTHOR = "BEDAPUDI PRANEETH" REQUIRES_PYTHON = ">=3.6.0" -VERSION = "0.0.2.dev9" +VERSION = "0.0.2.dev10" # What packages are required for this module to be executed? REQUIRED = [