[modules/battery] Add warning log if no estimates
This commit is contained in:
parent
7cdcde0080
commit
867e87913d
1 changed files with 3 additions and 2 deletions
|
@ -14,10 +14,12 @@ Parameters:
|
||||||
import os
|
import os
|
||||||
import glob
|
import glob
|
||||||
import logging
|
import logging
|
||||||
|
log = logging.getLogger(__name__)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import power
|
import power
|
||||||
except ImportError:
|
except ImportError:
|
||||||
pass
|
log.warning('unable to import module "power": Time estimates will not be available')
|
||||||
|
|
||||||
import core.module
|
import core.module
|
||||||
import core.widget
|
import core.widget
|
||||||
|
@ -25,7 +27,6 @@ import core.input
|
||||||
|
|
||||||
import util.format
|
import util.format
|
||||||
|
|
||||||
log = logging.getLogger(__name__)
|
|
||||||
|
|
||||||
class Module(core.module.Module):
|
class Module(core.module.Module):
|
||||||
def __init__(self, config=None):
|
def __init__(self, config=None):
|
||||||
|
|
Loading…
Reference in a new issue