Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions source/_integrations/logger.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,14 @@ where **namespace** is the *<component_namespace>* currently logging.
'&lt;component_namespace&gt;':
description: Logger namespace of the component. See [log_level](#log-levels).
type: string
filters:
description: Regular Expression logging filters.
required: false
type: map
keys:
'&lt;component_namespace&gt;':
description: Logger namespace of the component and a list of Regular Expressions. See [Log Filters](#log-filters).
type: list
{% endconfiguration %}

In the example, do note the difference between 'glances_api' and 'homeassistant.components.glances' namespaces,
Expand All @@ -110,6 +118,26 @@ Possible log severity levels, listed in order from most severe to least severe,
- debug
- notset

### Log Filters

Service-specific Regular Expression filters for logs. A message is omitted if it matches the Regular Expression.

An example configuration might look like this:

```yaml
# Example configuration.yaml entry
logger:
default: info
logs:
custom_components.my_integration: critical
filters:
custom_component.my_integartion:
- "HTTP 429" # Filter all HTTP 429 errors
- "Request to .*unreliable.com.* Timed Out"
homeassistant.components.nws:
- "^Error handling request$"
```

## Services

### Service `set_default_level`
Expand Down