From 0682f1465cd868b9bf82294a8141d77ab27c849d Mon Sep 17 00:00:00 2001 From: Francisco Ramirez Date: Tue, 7 Dec 2021 15:01:00 +0100 Subject: [PATCH] Add `validate_table_existence` to abstract `SettingsManager` (#5236) The `BackendManager` was using the `validate_table_existence` from its `SettingsManager` member, but this method was not defined in the abstract class. It was present in both backends implementations, but there would be nothing requiring from the abstract parent class. Co-authored-by: Chris Sewell --- aiida/backends/manager.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/aiida/backends/manager.py b/aiida/backends/manager.py index 404f5446ae..112f785a18 100644 --- a/aiida/backends/manager.py +++ b/aiida/backends/manager.py @@ -94,6 +94,13 @@ def delete(self, key): :raises: `~aiida.common.exceptions.NotExistent` if the settings does not exist """ + @abc.abstractmethod + def validate_table_existence(self): + """Verify that the `DbSetting` table actually exists. + + :raises: `~aiida.common.exceptions.NotExistent` if the settings table does not exist + """ + class BackendManager: """Class to manage the database schema and environment."""