PiotrMachowski / Home-Assistant-custom-components-SmartThings-Soundbar

Samsung Smarthings API for controlling Soundbar
MIT License
92 stars 24 forks source link

Crashes on HASS 2024.5.0b1 #66

Closed aherbjornsen closed 7 months ago

aherbjornsen commented 7 months ago

I tried to upgrade to the latest beta of HA (2024.5.0b1) and this caused the integration (and all my media center automations) to crash with the following error message:

RuntimeError: Detected that custom integration 'smartthings_soundbar' calls async_write_ha_state from a thread at custom_components/smartthings_soundbar/api.py, line 104: self.async_schedule_update_ha_state(). Please report it to the author of the 'smartthings_soundbar' custom integration.

I've reverted back to 2024.4 for now, and the integration is working again.

I also see this notice at startup, but assume that this is currently a minor issue:

2024-04-28 10:05:28.355 WARNING (MainThread) [homeassistant.helpers.entity] Entity media_player.soundbar (<class 'custom_components.smartthings_soundbar.media_player.SmartThingsSoundbarMediaPlayer'>) is using deprecated supported features values which will be removed in HA Core 2025.1. Instead it should use <MediaPlayerEntityFeature.PAUSE|VOLUME_SET|VOLUME_MUTE|TURN_ON|TURN_OFF|VOLUME_STEP|SELECT_SOURCE|PLAY: 19853>, please create a bug report at https://github.com/PiotrMachowski/Home-Assistant-custom-components-SmartThings-Soundbar/issues and reference https://developers.home-assistant.io/blog/2023/12/28/support-feature-magic-numbers-deprecation

PiotrMachowski commented 7 months ago

Fixed in v1.0.3

aherbjornsen commented 7 months ago

Brilliant, thanks for the quick fix. Will upgrade and test it soon.

aherbjornsen commented 7 months ago

Confirmed working on 2024.5.0b4

PiotrMachowski commented 7 months ago

@aherbjornsen great, thank you!