Locate all entry points by the name 'pmxbot_filters', each of
	which should refer to a callable(channel, msg) that must return
	True for the message not to be excluded.
189160
def _load_filters():
	
	group = 'pmxbot_filters'
	eps = entrypoints.get_group_all(group=group)
	return [ep.load() for ep in eps]
445663
def _find_entry_call(self, frames):
        """"""

        back_i = 0
        pout_path = self._get_src_file(self.modname)
        for frame_i, frame in enumerate(frames):
            if frame[1] == pout_path:
                back_i = frame_i

        return Call(frames[back_i])
1373304
def filter(self, filter):
        """"""
        if hasattr(filter, '__call__'):
            return [entry for entry in self.entries if filter(entry)]
        else:
            pattern = re.compile(filter, re.IGNORECASE)
            return [entry for entry in self.entries if pattern.match(entry)]
794536
def _get_callers(items, stage, special_cases=False):
    
    callers = utils.deepish_copy(_CALLERS[stage])
    if special_cases and "cnvkit" in callers:
        has_lumpy = any("lumpy" in get_svcallers(d) or "lumpy" in d["config"]["algorithm"].get("svcaller_orig", [])
                        for d in items)
        if has_lumpy and any("lumpy_usecnv" in dd.get_tools_on(d) for d in items):
            if stage != "initial":
                del callers["cnvkit"]
        else:
            if stage != "standard":
                del callers["cnvkit"]
    return callers
1276409
def _execFilters(self, type, msg):
        
        for filter in self.FILTERS:
            msg = filter(type, msg)
        return msg
42919
def detectCustomImportPaths(self, prefix):
		
		for assignment in self.ip2pp_mapping:
			if prefix.startswith(assignment["ipprefix"]):
				return {"prefix": assignment["ipprefix"], "provider_prefix": assignment["provider_prefix"]}

		return {}
1170406
def set_entry_points(self, names):
        
        names = util.return_set(names)
        self.entry_point_names = names
567441
def _get_all_filtered_channels(self, topics_without_signature):
        
        mpe_address     = self.get_mpe_address()
        event_signature = self.ident.w3.sha3(text="ChannelOpen(uint256,uint256,address,address,address,bytes32,uint256,uint256)").hex()
        topics = [event_signature] + topics_without_signature
        logs = self.ident.w3.eth.getLogs({"fromBlock" : self.args.from_block, "address"   : mpe_address, "topics"    : topics})
        abi           = get_contract_def("MultiPartyEscrow")
        event_abi     = abi_get_element_by_name(abi, "ChannelOpen")
        channels_ids  = [get_event_data(event_abi, l)["args"]["channelId"] for l in logs]
        return channels_ids
782795
public Iterator<BaseMessageFilter> getFilterList(BaseMessageHeader messageHeader)
    {
        if (messageHeader == null)
            return super.getFilterList(messageHeader);  // ALL The filters
        return this.getRegistry().getFilterList(messageHeader);
    }
1098140
def process_message(self, message, is_started=False):
        
        if not self.master:
            return False

        if 'status' not in message:
            return False
        message['name'] = message['turret']
        del message['turret']
        if not self.add(message, is_started):
            return self.update(message)
        return True
576413
def logs(channel):
	""
	default_url = 'http://' + socket.getfqdn()
	base = pmxbot.config.get('logs URL', default_url)
	logged_channel = channel in pmxbot.config.log_channels
	path = '/channel/' + channel.lstrip('#') if logged_channel else '/'
	return urllib.parse.urljoin(base, path)
798981
def msg_callback(self, callback):
        """"""
        if callable(callback):
            self._msg_callback = callback
        else:
            self._msg_callback = None
1204081
public boolean isFilterMatch(BaseMessageHeader messageHeader)
    {
        boolean bMatch = super.isFilterMatch(messageHeader);
        if (bMatch)
        {
            if (!(messageHeader instanceof RecordMessageHeader))
                return false;   // Never
            if (m_iDatabaseType != -1)
                if (m_iDatabaseType != ((RecordMessageHeader)messageHeader).getDatabaseType())
                    return false;   // No match
        }
        return bMatch;  // Match
    }
936455
def on_message(self, message):
        
        if message.address != self._address:
            return
        if isinstance(message, velbus.ChannelNamePart1Message) or isinstance(message, velbus.ChannelNamePart1Message2):
            self._process_channel_name_message(1, message)
        elif isinstance(message, velbus.ChannelNamePart2Message) or isinstance(message, velbus.ChannelNamePart2Message2):
            self._process_channel_name_message(2, message)
        elif isinstance(message, velbus.ChannelNamePart3Message) or isinstance(message, velbus.ChannelNamePart3Message2):
            self._process_channel_name_message(3, message)
        elif isinstance(message, velbus.ModuleTypeMessage):
            self._process_module_type_message(message)
        else:
            self._on_message(message)
488061
def pagure_specific_project_filter(config, message, project=None, *args, **kw):
    

    if not pagure_catchall(config, message):
        return False

    project = kw.get('project', project)
    link = fedmsg.meta.msg2link(message, **config)
    if not link:
        return False

    project = project.split(',') if project else []

    valid = False
    for proj in project:
        if '://pagure.io/%s/' % proj.strip() in link:
            valid = True

    return valid
425894
def msg_filter(self):
        
        if self.query:
            msg_filter = None
        else:
            msg_filter = self._request_request('msg_filter', 'all')
            available_msg_filters = {'untranslated', 'translated', 'fuzzy', 'all'}
            if msg_filter not in available_msg_filters:
                msg_filter = 'all'
        return msg_filter
36225
def get_filter_args_for_specific_event_from_channel(
        token_network_address: TokenNetworkAddress,
        channel_identifier: ChannelID,
        event_name: str,
        contract_manager: ContractManager,
        from_block: BlockSpecification = GENESIS_BLOCK_NUMBER,
        to_block: BlockSpecification = 'latest',
):
    
    if not event_name:
        raise ValueError('Event name must be given')

    event_abi = contract_manager.get_event_abi(CONTRACT_TOKEN_NETWORK, event_name)

    # Here the topics for a specific event are created
    # The first entry of the topics list is the event name, then the first parameter is encoded,
    # in the case of a token network, the first parameter is always the channel identifier
    _, event_filter_params = construct_event_filter_params(
        event_abi=event_abi,
        contract_address=to_checksum_address(token_network_address),
        argument_filters={
            'channel_identifier': channel_identifier,
        },
        fromBlock=from_block,
        toBlock=to_block,
    )

    return event_filter_params