def _load_filter(self, config):
        """ Load the filter file and populates self._devices accordingly """
        path = pathlib.Path(config)
        if not path.is_file():
            return

        with open(config, 'r') as conf:
            devices = yaml.load(conf)['devices']
            for ha_id, dev in devices.items():
                self._devices[dev['scs_id']] = {
                    ha_id: dev,
                    'name': dev['name']}
def _load_filter ( self , config ) : path = pathlib . Path ( config ) if not path . is_file ( ) : return with open ( config , 'r' ) as conf : devices = yaml . load ( conf ) [ 'devices' ] for ha_id , dev in devices . items ( ) : self . _devices [ dev [ 'scs_id' ] ] = { ha_id : dev , 'name' : dev [ 'name' ] }
Load the filter file and populates self._devices accordingly