diff --git a/ArtNet/db/db_adapter.py b/ArtNet/db/db_adapter.py index 2da7309..65cbbd4 100644 --- a/ArtNet/db/db_adapter.py +++ b/ArtNet/db/db_adapter.py @@ -639,7 +639,7 @@ class DBAdapter: for alias in aliases: self.add_alias_by_name(name, alias) for implicant in implications: - self.add_implication_by_name(name, implicant) + self.add_implication_by_ID(self.get_tag_ID(name), implicant['id']) self.db.commit() @@ -755,6 +755,7 @@ class DBAdapter: d) self.db.commit() + @DeprecationWarning def add_implication_by_name(self, name: str, implicant: str): """ Add the implication to the database @@ -762,6 +763,8 @@ class DBAdapter: :param implicant: :return: """ + logging.warning("This method is deprecated! Please resolve the name and use add_implication_by_id() instead.") + print(f"Name: {name} ({self.get_tag_ID(name)}), implcant: {implicant} ({self.get_tag_ID(implicant)})") self.add_implication_by_ID(self.get_tag_ID(name), self.get_tag_ID(implicant)) def remove_implication_by_ID(self, tag: int, implicant: int):