mirror of
https://github.com/ChuckBuilds/LEDMatrix.git
synced 2026-04-11 21:33:00 +00:00
Configure calendar manager logger to show DEBUG messages
This commit is contained in:
@@ -13,8 +13,9 @@ from rgbmatrix import graphics
|
||||
import pytz
|
||||
from src.config_manager import ConfigManager
|
||||
|
||||
# Get logger without configuring
|
||||
# Configure logger for this module
|
||||
logger = logging.getLogger(__name__)
|
||||
logger.setLevel(logging.DEBUG) # Set to DEBUG to see all messages
|
||||
|
||||
class CalendarManager:
|
||||
def __init__(self, matrix, canvas, config):
|
||||
@@ -43,11 +44,13 @@ class CalendarManager:
|
||||
try:
|
||||
self.timezone = pytz.timezone(timezone_str)
|
||||
except pytz.UnknownTimeZoneError:
|
||||
logging.warning(f"Unknown timezone '{timezone_str}' in config, defaulting to UTC.")
|
||||
logger.warning(f"Unknown timezone '{timezone_str}' in config, defaulting to UTC.")
|
||||
self.timezone = pytz.utc
|
||||
|
||||
if self.enabled:
|
||||
self.authenticate()
|
||||
else:
|
||||
logger.warning("Calendar manager is disabled in configuration")
|
||||
|
||||
# Display properties
|
||||
self.text_color = (255, 255, 255) # White
|
||||
|
||||
Reference in New Issue
Block a user