From 7e772d1cc88af1dd774a7153e6791b8e51c239cb Mon Sep 17 00:00:00 2001 From: Dylan Date: Wed, 10 Jan 2024 14:04:14 +1100 Subject: [PATCH 1/2] Fix unnecessary `raise e` --- data_interrogator/interrogators.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/data_interrogator/interrogators.py b/data_interrogator/interrogators.py index a5c781e..4e78f1d 100755 --- a/data_interrogator/interrogators.py +++ b/data_interrogator/interrogators.py @@ -196,7 +196,7 @@ def is_translatable(self, column) -> bool: """Return whether a forbidden field exists in the query""" if not GARNETT_ENABLED: return False - + checking_model = self.base_model joins = list(enumerate(column.split('__'))) @@ -502,14 +502,13 @@ def interrogate(self, base_model, columns=None, filters=None, order_by=None, lim errors.append("The requested field '%s' was not found in the database." % field) else: errors.append("An error was found with your query:\n%s" % e) - raise e except Exception as e: rows = [] errors.append("Something went wrong - %s" % e) return { 'rows': rows, 'count': count, 'columns': output_columns, 'errors': errors, - 'base_model': base_model_data, + 'base_model': base_model_data, # 'query': query # DEBUG Tool } From 28eb2aecb04a6c56da2222c8108b27f789eec5d4 Mon Sep 17 00:00:00 2001 From: Dylan Date: Wed, 10 Jan 2024 14:05:01 +1100 Subject: [PATCH 2/2] Bump to 0.3.4 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f3c43cc..7216236 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "django-data-interrogator" -version = "0.3.3" +version = "0.3.4" description = "A suite of interactive table builder utilities that create reports using efficient SQL queries" authors = ["Aristotle Metadata Enterprises"] license = "BSD-3-Clause"