add manage_switch_off_timers to the deps run at each checkin.
self,
name: str,
mac: str,
- keywords: Optional[List[str]],
+ keywords: Optional[str] = "",
):
self.name = name
self.mac = mac
self.keywords = keywords
self.arper = arper.Arper()
if keywords is not None:
- self.kws = keywords
+ self.kws: List[str] = keywords.split(' ')
else:
self.kws = []
@timeout(10.0, use_signals=False, error_message="Timed out waiting for tplink.py")
def get_info(self) -> Optional[Dict]:
cmd = self.get_cmdline() + "-c info"
+ logger.debug(f'Getting status of {self.mac} via "{cmd}"...')
out = subprocess.getoutput(cmd)
logger.debug(f'RAW OUT> {out}')
out = re.sub("Sent:.*\n", "", out)
"/home/scott/bin/tplink.py -a office_lights -c info --audit_import_events >& /dev/null",
"/home/scott/bin/unscramble.py ethyropadratoyzrhoiectmi --trace_memory >& /dev/null",
"/home/scott/bin/cron.py --command='sleep 0' --lockfile=/tmp/deleteme_lock >& /dev/null",
+ "/home/scott/cron/manage_switch_off_timers.py >& /dev/null",
]
for command in commands:
try: