Skip to content

Commit

Permalink
undo logger none removal
Browse files Browse the repository at this point in the history
  • Loading branch information
nazunalika committed Dec 23, 2023
1 parent 8481efd commit 62d8d6a
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions iso/empanadas/empanadas/util/dnf_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -1806,16 +1806,17 @@ def __init__(
)

# This is temporary for now.
self.log = logging.getLogger("sigreposync")
self.log.setLevel(getattr(logging, logger.upper(), 'INFO'))
handler = logging.StreamHandler(sys.stdout)
handler.setLevel(logging.INFO)
formatter = logging.Formatter(
'%(asctime)s :: %(name)s :: %(message)s',
'%Y-%m-%d %H:%M:%S'
)
handler.setFormatter(formatter)
self.log.addHandler(handler)
if logger is None:
self.log = logging.getLogger("sigreposync")
self.log.setLevel(getattr(logging, logger.upper(), 'INFO'))
handler = logging.StreamHandler(sys.stdout)
handler.setLevel(logging.INFO)
formatter = logging.Formatter(
'%(asctime)s :: %(name)s :: %(message)s',
'%Y-%m-%d %H:%M:%S'
)
handler.setFormatter(formatter)
self.log.addHandler(handler)

self.log.info('sig reposync init')
self.log.info(self.profile + ' ' + self.major_version)
Expand Down

0 comments on commit 62d8d6a

Please sign in to comment.