Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GMail OAuth2 Support (gmail://) #1250

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions apprise/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,11 @@
# from the command line. The idea here is to allow for deprecation notices
logging.DEPRECATE = logging.ERROR + 1

# Action Required Notices
logging.ACTION_REQUIRED = logging.ERROR + 2

# Assign our Levels into our logging object
logging.addLevelName(logging.ACTION_REQUIRED, "ACTION REQUIRED")
logging.addLevelName(logging.DEPRECATE, "DEPRECATION WARNING")
logging.addLevelName(logging.TRACE, "TRACE")

Expand All @@ -61,9 +65,18 @@
self._log(logging.DEPRECATE, message, args, **kwargs)


def action_required(self, message, *args, **kwargs):
"""
Action Required Logging
"""
if self.isEnabledFor(logging.ACTION_REQUIRED):
self._log(logging.ACTION_REQUIRED, message, args, **kwargs)

Check warning on line 73 in apprise/logger.py

View check run for this annotation

Codecov / codecov/patch

apprise/logger.py#L73

Added line #L73 was not covered by tests


# Assign our Loggers for use in Apprise
logging.Logger.trace = trace
logging.Logger.deprecate = deprecate
logging.Logger.action_required = action_required

# Create ourselve a generic (singleton) logging reference
logger = logging.getLogger(LOGGER_NAME)
Expand Down
Loading
Loading