From 57397facdeb03aa254aa4a4839a5139bcb220112 Mon Sep 17 00:00:00 2001 From: Tushar Saini Date: Thu, 11 Jul 2024 15:47:54 +0530 Subject: [PATCH 1/2] [UPD] Improve within angle search method --- retailtree/retailtree.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/retailtree/retailtree.py b/retailtree/retailtree.py index a49b0dc..0f20514 100644 --- a/retailtree/retailtree.py +++ b/retailtree/retailtree.py @@ -105,10 +105,13 @@ def __fetching_ann_in_range(self, result_dict, min_angle, max_angle, result_lst) elif max_angle is None and min_angle < result_dict['angle']: result_lst.append(result_dict) elif min_angle is not None and max_angle is not None: - if min_angle <= result_dict['angle'] <= max_angle: - result_lst.append(result_dict) - else: - pass + if min_angle <= max_angle: + if min_angle <= result_dict['angle'] <= max_angle: + result_lst.append(result_dict) + else: + if min_angle <= result_dict['angle'] or max_angle >= result_dict['angle']: + result_lst.append(result_dict) + # if min_angle is None: return result_lst From 97348294937e1ae376041af3c4c43d5d40d16a93 Mon Sep 17 00:00:00 2001 From: Tushar Saini Date: Thu, 11 Jul 2024 15:50:53 +0530 Subject: [PATCH 2/2] [UPD] version update --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index cd927fa..7273f8c 100644 --- a/setup.py +++ b/setup.py @@ -9,7 +9,7 @@ def read(fname): setup( name="retailtree", - version="1.3.1", + version="1.3.2", long_description=read("README.md"), long_description_content_type='text/markdown', packages=find_packages(),