Убрал лишние поля у класса. Выделил важные сообщения разными цветами

This commit is contained in:
2025-05-22 16:57:03 +03:00
parent 409c0651d5
commit eb69a29486
5 changed files with 27 additions and 24 deletions

View File

@@ -48,8 +48,8 @@ class Database:
)
)
self.con.commit()
except Exception as e:
logger.debug(e)
except Exception:
pass
if not is_updated:
logging.info("База данных устарела. Рекомендуем обновить с помощью флага -i [--init-db]")
@@ -72,8 +72,8 @@ class Database:
)
)
self.con.commit()
except Exception as e:
logger.debug(e)
except Exception:
pass
def insert_tags(self, tags: list[Tag]):
@@ -82,8 +82,8 @@ class Database:
try:
cur.execute("INSERT INTO tags VALUES(?, ?)",(tag.id,tag.title))
self.con.commit()
except Exception as e:
logger.debug(e)
except Exception:
pass
def insert_vetro_projects(self, vetro_projects: list[VetroProject]):
@@ -92,8 +92,8 @@ class Database:
try:
cur.execute("INSERT INTO vetro_projects VALUES(?, ?)", (vetro_project.id, vetro_project.title))
self.con.commit()
except Exception as e:
logger.debug(e)
except Exception:
pass
def insert_activity_types(self, activity_types: list[ActivityType]):
cur = self.con.cursor()
@@ -101,5 +101,5 @@ class Database:
try:
cur.execute("INSERT INTO activity_types VALUES(?, ?)", (activity_type.id, activity_type.title))
self.con.commit()
except Exception as e:
logger.debug(e)
except Exception:
pass