misc(aurora): change the logging severity of Change.from_dict()'s logs to trace
Some checks failed
Actions / Build Documentation (MkDocs) (pull_request) Successful in 27s
Actions / Lint Code (Ruff & Pylint) (pull_request) Failing after 41s

This commit is contained in:
Seaswimmer 2024-05-06 16:39:13 -04:00
parent 15ccd5530a
commit 09471a4027
Signed by: cswimr
GPG key ID: 5D671B5D03D65A7F

View file

@ -360,10 +360,10 @@ class Change(AuroraBaseModel):
@classmethod
def from_dict(cls, bot: Red, data: dict) -> "Change":
logger.debug("Creating Change from dict (%s): %s", type(data), data)
logger.trace("Creating Change from dict (%s): %s", type(data), data)
if isinstance(data, str):
data = json.loads(data)
logger.debug("Change data was a string, converted to dict: %s", data)
logger.trace("Change data was a string, converted to dict: %s", data)
if "duration" in data and data["duration"] and not isinstance(data["duration"], timedelta):
hours, minutes, seconds = map(int, data["duration"].split(':'))
duration = timedelta(hours=hours, minutes=minutes, seconds=seconds)