Using logger string formatting

This commit is contained in:
Felipe Martin 2017-04-03 21:27:19 +02:00
parent 5e1705856a
commit 987d11fa94
1 changed files with 2 additions and 1 deletions

View File

@ -45,7 +45,8 @@ def get_matching_led(led: str) -> hex:
if led_number:
return led_number
logger.info('Led(s) %s not found, falling back to all' % led)
logger.info('Led(s) %(led)s not found, falling back to all',
extra={'led': led})
return luxafor.Leds.ALL