diff --git a/CHANGELOG.md b/CHANGELOG.md index 6ff3bc5..cf4b6d5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,15 @@ # Changelog for SecuritySpy Home Assistant Integration +## Version 1.1.9 + +Release date: `2024-09-23` + +**NOTE** I do not have access to the latest version of SecuritySpy, neither do I use it in my home, so these changes have only been tested against an older V5.x system which was temporarely installed. I also have to state that I do NOT maintain this Module anymore, as I simply don't have the resources. If I can I will try and fix issues like this, but eventually the Integration will most likely stop working due to changes in Home Assistant. + +### Changes + +- Fixing deprecating warnings occuring in HA 2024.9. Closing Issue [#98](https://github.com/briis/securityspy/issues/98) and [#99](https://github.com/briis/securityspy/issues/99) + ## Version 1.1.8 Release date: `2024-01-05` diff --git a/custom_components/securityspy/camera.py b/custom_components/securityspy/camera.py index 845f8fc..f45582c 100644 --- a/custom_components/securityspy/camera.py +++ b/custom_components/securityspy/camera.py @@ -54,7 +54,7 @@ async def async_setup_entry( async_add_entities(cameras) - platform = entity_platform.current_platform.get() + platform = entity_platform.async_get_current_platform() _LOGGER.debug("Creating Service: Set Arm Mode") platform.async_register_entity_service( @@ -194,3 +194,4 @@ def _write_file(to_file, content): with open(to_file, "wb") as _file: _file.write(content) _LOGGER.debug("File written to %s", to_file) + diff --git a/custom_components/securityspy/const.py b/custom_components/securityspy/const.py index 925f4b7..d03f812 100644 --- a/custom_components/securityspy/const.py +++ b/custom_components/securityspy/const.py @@ -61,25 +61,13 @@ SERVICE_DOWNLOAD_LATEST_MOTION_RECORDING = "download_latest_motion_recording" SERVICE_ENABLE_SCHEDULE_PRESET = "enable_schedule_preset" SERVICE_SET_ARM_MODE = "set_arm_mode" -DOWNLOAD_LATEST_MOTION_RECORDING_SCHEMA = vol.Schema( - { - vol.Required(ATTR_ENTITY_ID): cv.entity_ids, - vol.Required(CONF_FILENAME): cv.string, - } -) +DOWNLOAD_LATEST_MOTION_RECORDING_SCHEMA = { vol.Required(ATTR_ENTITY_ID): cv.entity_ids, vol.Required(CONF_FILENAME): cv.string,} ENABLE_SCHEDULE_PRESET_SCHEMA = vol.Schema( { vol.Required(ATTR_PRESET_ID): cv.string, } ) -SET_ARM_MODE_SCHEMA = vol.Schema( - { - vol.Required(ATTR_ENTITY_ID): cv.entity_ids, - vol.Required(CONF_MODE): vol.In(VALID_MODES), - vol.Required(CONF_ENABLED): cv.boolean, - } -) - +SET_ARM_MODE_SCHEMA = { vol.Required(ATTR_ENTITY_ID): cv.entity_ids, vol.Required(CONF_MODE): vol.In(VALID_MODES), vol.Required(CONF_ENABLED): cv.boolean,} SECURITYSPY_PLATFORMS = [ "camera", "binary_sensor", @@ -87,3 +75,4 @@ "switch", "button", ] + diff --git a/custom_components/securityspy/manifest.json b/custom_components/securityspy/manifest.json index f5ecc39..f112092 100644 --- a/custom_components/securityspy/manifest.json +++ b/custom_components/securityspy/manifest.json @@ -12,5 +12,5 @@ "requirements": [ "pysecspy==1.3.5" ], - "version": "1.1.8" -} + "version": "1.1.9" +} \ No newline at end of file diff --git a/hacs.json b/hacs.json index c219f93..e2f43fe 100644 --- a/hacs.json +++ b/hacs.json @@ -1,5 +1,4 @@ { "name": "SecuritySpy for Home Assistant", - "render_readme": true, "homeassistant": "2021.11.0" -} +} \ No newline at end of file