You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It is possible run into an exception when a rule_tree is wrongly configured.
Expected behavior
Logprep compains already on startup that the rule_tree_config is not correct, and the rule_tree should have a logger in case other unforeseen errors happen.
Current behavior
In an older logprep version one could see following logline, if the rule was not configured as a separate file, but defined directly inside the pipeline.yaml
RuleTree WARNING : Error parsing rule "None.yml": TypeError: '<' not supported between instances of 'int' and 'str'. Ignore and continue with next rule.
This is not very helpful as it is not easily recognizable which rule or rule_tree is producing this error. In the current main branch though this doesn't even happen anymore as the rule_tree doesn't have a logger resulting in:
[...]
File "[...]/logprep/framework/rule_tree/rule_tree.py", line 125, in add_rule
logger.warning(
^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'warning'
Steps to reproduce
Create the following pipeline.yml:
It is possible run into an exception when a rule_tree is wrongly configured.
Expected behavior
Logprep compains already on startup that the rule_tree_config is not correct, and the rule_tree should have a logger in case other unforeseen errors happen.
Current behavior
In an older logprep version one could see following logline, if the rule was not configured as a separate file, but defined directly inside the
pipeline.yaml
This is not very helpful as it is not easily recognizable which rule or rule_tree is producing this error. In the current main branch though this doesn't even happen anymore as the rule_tree doesn't have a logger resulting in:
Steps to reproduce
Create the following
pipeline.yml
:Create the following
tree_config
namedtconfig.json
(as referenced inside thepipeline.yml
):Notice that the
priority_dict
uses integer values instead of string values.Run logprep with:
Environment
Logprep version: 856ceaf
Python version: 3.11.0
Possible solution
The text was updated successfully, but these errors were encountered: