Recorder exclusion list isn't excluding anything

It will still show the current state. Which is all I can see in your screenshot.

The colored line shows that it’s still logging previous states.

Here’s the history from today:

That should be covered by recorder.exclude.entity_globs: sensor.*_beacon, but it is not.

Do you have any includes or is that your entire recorder config?

That is the entire config.

Hmm. Looks like a bug to me then.

There were a few bugs with glob excludes in the past but they have all been fixed.

You should open a new issue here:

@Mariusthvdb are your entity_globs excludes still working?

uhm, as far as I can see yes, all good here.

not sure if OP is using excludes too, but it might be worth checking this setting in excluded_entities

##########################################################################################
# uncomment domains sensor and device_tracker below, to be able to use
# include_globs in included_entities.yaml
# domains person and switch are included in included_entities.yaml
##########################################################################################

domains:
  - alarm_control_panel
  - alert
  - automation
#  - binary_sensor
  - button
  - camera
  - climate
  - counter
  - cover
#  - device_tracker
  - geo_location
  - group
  - input_boolean
  - input_datetime
  - input_number
  - input_select
  - input_text
  - light
  - media_player
  - number
#  - person
  - proximity
  - remote
  - scene
  - script
#  - sensor
  - sun
#  - switch
  - timer
  - updater
  - variable
  - weather
  - zone

it was the only peculiarity I had to iron out at that time

Yeah they’re only excluding entity_globs and entities, no domains, no includes.

@TurfFiber do the explicitly defined entity_ids (e.g. sensor.valetudo_dreame_fan) get excluded form the recorder?

No, nothing is excluded. Seems like the exclude list is completely ignored.

Where did you put this recorder: config?

Are there any relevant errors in your logs?

ok, I just checked all I have excluded, and they are in fact all excluded, be it entity_globs, entities, domains or event_types

otoh, I also have a carefully curated included_entities list.

Top level in configuration.yaml, no error logs.

1 Like

Well that is very odd. My explicit excludes are working, however I use MariaDB. So maybe it could be an issue with the default SQLite database?

You definitely restarted HA rather than reloading YAML?

What core version are you on?

Also tried removing the #db_url comment from the config, didn’t help.

2023.09.2

I started configuring the recorder because I was planning on switching to mariaDB, but that will take me a couple of days to configure.

fwiw, I moved from MariaDB to builtin SQLite, and use this in the recorder config:

# db_url: !secret db_url
purge_keep_days: 5

# https://www.home-assistant.io/integrations/recorder/#configure-filter
exclude:
  !include excluded_entities.yaml

include:
  !include included_entities.yaml

the paste from above is from my excluded_entities.yaml

got to add this whole recorder config is from way back, when MariaDB was still the main suggestion/recommendation to use for DB. As it stands, current SQLite is supposed to have improved so much, that we dont need to bother ourselves with that anymore, and, depending on the amount of entities, probably dont even have to in/exclude anything at all.

I have a huge amount of entities, so try to keep that number down, but you might not need it in the first place.

1 Like

Ok so it is something specific to TurfFiber’s install.

Just had a thought. TurfFiber, try clearing your web browser cache or try using private/incognito mode in your browser.

No dice, history also shows on my phone app, it’s not the cache.

What’s a huge number, and how could I get my total number of entities?

Put this in Developer Tools → Template

{%- for d in states | groupby('domain') %}
{{ d[0] }}: {{ states[d[0]] | count  }}
{%- endfor %}

It’ll give you something like this:

alarm_control_panel: 1
automation: 287
binary_sensor: 219
button: 114
calendar: 5
camera: 17
climate: 3
device_tracker: 3
group: 10
image: 5
input_boolean: 55
input_datetime: 21
input_number: 35
input_select: 10
light: 87
lock: 2
media_player: 12
number: 22
remote: 2
scene: 35
schedule: 2
script: 166
select: 29
sensor: 791
stt: 1
sun: 1
switch: 123
tts: 1
update: 25
vacuum: 2
weather: 3
zone: 6

I’m not sure about huge but this is getting a bit silly, sensor: 791

Okay, maybe I don’t need mariadb, or even to exclude stuff.

alarm_control_panel: 1
automation: 48
binary_sensor: 68
button: 14
camera: 6
device_tracker: 18
fan: 1
group: 3
input_boolean: 23
input_number: 3
input_text: 6
light: 5
media_player: 20
number: 11
remote: 1
script: 17
select: 16
sensor: 122
stt: 1
sun: 1
switch: 57
tts: 1
update: 24
vacuum: 1
weather: 1
zone: 1

It depends on a couple of things,

  1. How chatty are your sensors?
  2. How powerful is your hardware?

Either way excludes still should work and I am at a loss to explain why yours are not working.