Any way to prevent Open Hardware Monitor from spamming my log when my PC is off?

I installed the Open Hardware Monitor integration as instructed on https://www.home-assistant.io/integrations/openhardwaremonitor/ last night and it’s overall worked pretty well for what I wanted it to, but I noticed when I woke up it generated warnings all night long when it was unable to connect to my PC anymore. Is there any way to disable this sensor/integration when the PC is off? (It’s already being pinged by a wake-on-lan switch so getting the current power state is easy enough.) I guess worst case I can just raise my logging level to error or something though would be nice if there was a better solution than that somehow…

Also kind of unrelated but is it possible to selectively disable some of the sensors added by this integration? It adds quite a lot that I don’t necessarily care to be keeping track of all the time. (Though maybe this is more of an issue with the open hardware monitor app since it seems like it’s just copying everything the web interface exposes.)

Read the LOG book section of Home assistant there is an ignore part, something like:

# Example filter to include specified domains and exclude specified entities
logbook:
  include:
    domains:
      - alarm_control_panel
      - light
    entity_globs:
      - binary_sensor.*_occupancy
  exclude:
    entities:
      - light.kitchen_light

home is what you needed

Will excluding something from the logbook also keep it out of the logger? I already set homeassistant.components.sensor and homeassistant.helpers.entity to error level from the warn that was my previous default which should hopefully reduce the amount of log spam though it would be easier if I could do it with a wildcard filter on specific entities like you showed above.

edit: Ahh now getting tons of these

2020-11-09 18:50:41 ERROR (MainThread) [homeassistant.helpers.entity] Update for sensor.desktop_q8p7fau_crucial_ct525mx300ssd1_data_total_bytes_written fails
Traceback (most recent call last):
File "/srv/homeassistant/lib/python3.8/site-packages/homeassistant/helpers/entity.py", line 278, in async_update_ha_state
await self.async_device_update()
File "/srv/homeassistant/lib/python3.8/site-packages/homeassistant/helpers/entity.py", line 474, in async_device_update
raise exc
File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
result = self.fn(*self.args, **self.kwargs)
File "/srv/homeassistant/lib/python3.8/site-packages/homeassistant/components/openhardwaremonitor/sensor.py", line 94, in update
values = array[path_number]
IndexError: list index out of range

even when the PC is on and responding… I think I’m just gonna disable this integration for now and try to find another way to send system stats over MQTT or something which would avoid all these issues. IOTLink was promosing (and I’m already using it for some other stuff) but unfortunately it’s not able to report temperature stats at this time.

Correct me if I’m wrong but doesn’t this disable logging of data to the recorder AKA database? I believe OP is asking how to disable logging of errors to the home-assistant.log file.

Below is what OP should be looking at.

This is what I’m using:

logger:
  default: warning
  logs:
    homeassistant.components.openhardwaremonitor: fatal