Skip to content

Commit

Permalink
fix: do not log stacktrace on db reconnect
Browse files Browse the repository at this point in the history
This is confusing and spams the log despite no actual error happening.
  • Loading branch information
winged committed Oct 31, 2024
1 parent 2efcf31 commit 8f0d753
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions manabi/lock.py
Original file line number Diff line number Diff line change
Expand Up @@ -300,9 +300,7 @@ def execute(self, *args, **kwargs):
try:
self._cursor.execute(*args, **kwargs)
except (InterfaceError, OperationalError):
_logger.error(
f"Postgres connection lost, reconnecting. {''.join(traceback.format_stack())}"
)
_logger.warn("Postgres connection lost, reconnecting")

self.connect()
self._cursor.execute(*args, **kwargs)
Expand Down

0 comments on commit 8f0d753

Please sign in to comment.