Skip to content

Commit

Permalink
Merge pull request #84 from cowprotocol/reduce_error_msgs_from_db
Browse files Browse the repository at this point in the history
Finally silence all write prices errors
  • Loading branch information
harisang authored Oct 31, 2024
2 parents ef50ecf + c44bb24 commit 2f01a32
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/helpers/database.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,11 +182,13 @@ def write_prices_new(self, prices: list[tuple[str, int, float, str]]) -> None:
"source": source,
},
)
except psycopg.errors.NumericValueOutOfRange:
logger.info(
f"Error while writing price data. token: {token_address}, "
f"time: {time}, price: {price}, source: {source}"
)
except Exception as err:
pass
# except psycopg.errors.NumericValueOutOfRange:
# logger.info(
# f"Error while writing price data. token: {token_address}, "
# f"time: {time}, price: {price}, source: {source}"
# )

def get_latest_transaction(self) -> str | None:
"""Get latest transaction hash.
Expand Down

0 comments on commit 2f01a32

Please sign in to comment.