Skip to content

Commit

Permalink
remove logger.error noise (#4374)
Browse files Browse the repository at this point in the history
observed a few errors in the log since latest hotfix rollout. the
situation no longer deserves error alert status, as the withdrawn users
will legitimately raise this error. dialed back to a `logger.warning`
just in case it helps with future debugging.

not critical to push live, unless the alerts are overwhelming.

example of error it was generating:
```
celeryworkerslow_1  | {"written_at": "2024-03-27T14:30:02.073Z", "written_ts": 1711549802073935000, "msg": "patient 5357 w/o cur_qbd??", "type": "log", "logger": "flask.app", "thread": "MainThread", "level": "ERROR", "module": "qb_status", "line_no": 99, "correlation_id": "7f2f63ac-ec46-11ee-b0e1-0242ac190006"}
celeryworkerslow_1  | 2024-03-27 14:30:02,073: patient 5357 w/o cur_qbd??
```
  • Loading branch information
pbugni committed Mar 27, 2024
1 parent 59ecdc7 commit 4953b1c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion portal/models/qb_status.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ def _sync_timeline(self):
" {} vs as_of {}".format(
self.__ordered_qbs[0].relative_start, self.as_of_date))
else:
current_app.logger.error(f"patient {self.user.id} w/o cur_qbd??")
current_app.logger.warning(f"patient {self.user.id} w/o cur_qbd??")
self._overall_status = OverallStatus.expired
self.next_qbd = self.__ordered_qbs[0]
return
Expand Down

0 comments on commit 4953b1c

Please sign in to comment.