def get_cool_off_threshold(attempt_time: datetime = None) -> datetime:
cool_off = get_cool_off()<EOL>if cool_off is None:<EOL><INDENT>raise TypeError('<STR_LIT>')<EOL><DEDENT>if attempt_time is None:<EOL><INDENT>return now() - cool_off<EOL><DEDENT>return attempt_time - cool_off<EOL>
Get threshold for fetching access attempts from the database.