There seems to be an issue with match method in the Drain class.
When configuring a template miner with a config file with masking (e.g. masking = [{"regex_pattern":"((?<=[^A-Za-z0-9])|^)([\\-\\+]?\\d+)((?=[^A-Za-z0-9])|$)", "mask_with": "NUM"}]) and mining all templates, it becomes impossible to match lines containing tokens that fit the regex patterns defined in the config file.
Example: with the same config file, imagine I get templates
ID=1 : size=100 : RAS node <:NUM:>ID=2 : size=10 : RAS error <:NUM:>.
Then template_miner.drain.match("RAS node 12334") will return None and not the first template.
There seems to be an issue with match method in the Drain class. When configuring a template miner with a config file with masking (e.g.
masking = [{"regex_pattern":"((?<=[^A-Za-z0-9])|^)([\\-\\+]?\\d+)((?=[^A-Za-z0-9])|$)", "mask_with": "NUM"}]
) and mining all templates, it becomes impossible to match lines containing tokens that fit the regex patterns defined in the config file.Example: with the same config file, imagine I get templates
ID=1 : size=100 : RAS node <:NUM:>
ID=2 : size=10 : RAS error <:NUM:>
. Thentemplate_miner.drain.match("RAS node 12334")
will return None and not the first template.