Xyaren / homeassistant-magentatv

Homeassistant Integration for controlling Telekom MagnetaTV Media Receivers
MIT License
4 stars 0 forks source link

Error adding entity media_player.magentatvlivingroom for domain media_player with platform magentatv #195

Closed hctom closed 1 month ago

hctom commented 1 month ago

System Health details

System Information

version core-2024.7.4
installation_type Home Assistant OS
dev false
hassio true
docker true
user root
virtualenv false
python_version 3.12.4
os_name Linux
os_version 6.6.31-haos-raspi
arch aarch64
timezone Europe/Berlin
config_dir /config
Home Assistant Community Store GitHub API | ok -- | -- GitHub Content | ok GitHub Web | ok GitHub API Calls Remaining | 4994 Installed Version | 1.34.0 Stage | running Available Repositories | 1391 Downloaded Repositories | 15 HACS Data | ok
Home Assistant Cloud logged_in | false -- | -- can_reach_cert_server | ok can_reach_cloud_auth | ok can_reach_cloud | ok
Home Assistant Supervisor host_os | Home Assistant OS 12.4 -- | -- update_channel | stable supervisor_version | supervisor-2024.06.2 agent_version | 1.6.0 docker_version | 26.1.4 disk_total | 28.5 GB disk_used | 7.1 GB healthy | true supported | true host_connectivity | true supervisor_connectivity | true ntp_synchronized | true virtualization | board | rpi5-64 supervisor_api | ok version_api | ok installed_addons | Terminal & SSH (9.14.0), Samba share (12.3.2), Studio Code Server (5.15.0)
Dashboards dashboards | 11 -- | -- resources | 11 views | 20 mode | storage
Recorder oldest_recorder_run | June 26, 2024 at 9:01 PM -- | -- current_recorder_run | July 30, 2024 at 3:58 PM estimated_db_size | 496.98 MiB database_engine | mysql database_version | 11.4.2
Xiaomi Miot Auto component_version | 0.7.19 -- | -- can_reach_server | ok can_reach_spec | ok logged_accounts | 1 total_devices | 1

Checklist

Describe the issue

I am currently having trouble with this extension in my HA 2024.7.4 install. The MagentaTV media player cannot be added. Please see the debug logs for more details about the errors. Hope this helps and thanks for this really required and helpful extension!

Reproduction steps

Not really sure, if there is a possibility to reproduce this issue from scratch, but I guess it will happen, when you try to add a new MagentaTV media receiver device/entity.

In my case it happens after HA update to 2024.7.x

Debug logs

2024-08-02 13:31:25.934 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration hacs which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-08-02 13:31:25.934 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration xiaomi_miot which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-08-02 13:31:25.935 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration magentatv which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-08-02 13:31:25.935 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration waste_collection_schedule which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-08-02 13:31:27.498 INFO (MainThread) [custom_components.magentatv] MagentaTV setup
2024-08-02 13:31:27.498 INFO (MainThread) [custom_components.magentatv] MagentaTV setup entry
2024-08-02 13:31:28.861 INFO (SyncWorker_7) [fritzconnection] Unable to retrieve resource 'http://192.168.1.3:49000/igddesc.xml' from the device.
2024-08-02 13:31:28.932 INFO (MainThread) [custom_components.magentatv] Setup Notify Server for MagentaTV
2024-08-02 13:31:28.935 DEBUG (MainThread) [custom_components.magentatv.api] Starting Notify Server on 0.0.0.0:11223 ...
2024-08-02 13:31:28.938 ERROR (MainThread) [homeassistant.components.media_player] Error adding entity media_player.magentatvlivingroom for domain media_player with platform magentatv
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 598, in _async_add_entities
    await coro
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 912, in _async_add_entity
    await entity.add_to_platform_finish()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1361, in add_to_platform_finish
    await self.async_added_to_hass()
  File "/config/custom_components/magentatv/media_player.py", line 172, in async_added_to_hass
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:31:29.981 WARNING (MainThread) [homeassistant.helpers.frame] Detected that custom integration 'hacs' calls hass.http.register_static_path which is deprecated because it does blocking I/O in the event loop, instead call `await hass.http.async_register_static_paths([StaticPathConfig("/hacsfiles/frontend", "/config/custom_components/hacs/hacs_frontend_experimental", False)])`; This function will be removed in 2025.7 at custom_components/hacs/frontend.py, line 49: hass.http.register_static_path(, please create a bug report at https://github.com/hacs/integration/issues
2024-08-02 13:31:29.988 WARNING (MainThread) [homeassistant.helpers.frame] Detected that custom integration 'hacs' calls hass.http.register_static_path which is deprecated because it does blocking I/O in the event loop, instead call `await hass.http.async_register_static_paths([StaticPathConfig("/hacsfiles/iconset.js", "/config/custom_components/hacs/iconset.js", True)])`; This function will be removed in 2025.7 at custom_components/hacs/frontend.py, line 57: hass.http.register_static_path(, please create a bug report at https://github.com/hacs/integration/issues
2024-08-02 13:31:29.993 WARNING (MainThread) [homeassistant.helpers.frame] Detected that custom integration 'hacs' accesses hass.components.frontend. This is deprecated and will stop working in Home Assistant 2024.9, it should be updated to import functions used from frontend directly at custom_components/hacs/frontend.py, line 68: hass.components.frontend.async_register_built_in_panel(, please create a bug report at https://github.com/hacs/integration/issues
2024-08-02 13:31:29.999 WARNING (MainThread) [homeassistant.helpers.frame] Detected that custom integration 'hacs' calls hass.http.register_static_path which is deprecated because it does blocking I/O in the event loop, instead call `await hass.http.async_register_static_paths([StaticPathConfig("/hacsfiles", "/config/www/community", True)])`; This function will be removed in 2025.7 at custom_components/hacs/base.py, line 1162: self.hass.http.register_static_path(, please create a bug report at https://github.com/hacs/integration/issues
2024-08-02 13:31:30.038 ERROR (MainThread) [homeassistant.components.sensor] Platform waste_collection_schedule does not generate unique IDs. ID Blaue Tonne: Nächste Leerung already exists - ignoring sensor.blaue_tonne_nachste_leerung
2024-08-02 13:31:38.983 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:31:41.207 WARNING (MainThread) [homeassistant.helpers.frame] Detected that custom integration 'hacs' accesses hass.helpers.event. This is deprecated and will stop working in Home Assistant 2024.11, it should be updated to import functions used from event directly at custom_components/hacs/base.py, line 642: self.hass.helpers.event.async_track_time_interval(, please create a bug report at https://github.com/hacs/integration/issues
2024-08-02 13:31:41.591 DEBUG (MainThread) [custom_components.magentatv] async_step_ssdp SsdpServiceInfo(ssdp_usn='uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5::upnp:rootdevice', ssdp_st='upnp:rootdevice', upnp={'UDN': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', 'friendlyName': 'Hctmagentatv', 'deviceType': 'urn:schemas-upnp-org:device:MediaRenderer:1', 'manufacturer': 'Huawei Technologies Co.,Ltd', 'modelName': 'MR401B_ACN', 'modelNumber': 'R01A5', 'productVersionNumber': '" 1243 "', 'productType': 'stb', 'serialNumber': None, 'X_wakeOnLan': '0', 'X_DLNADOC': 'DMR-1.50', 'X_DLNACAP': None, 'serviceList': {'service': [{'serviceType': 'urn:schemas-upnp-org:service:ConnectionManager:1', 'serviceId': 'urn:upnp-org:serviceId:ConnectionManager', 'controlURL': '/upnp/service/ConnectionManager/Control', 'eventSubURL': '/upnp/service/ConnectionManager/Event', 'SCPDURL': '/upnp/service/des/cms.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:AVTransport:1', 'serviceId': 'urn:upnp-org:serviceId:AVTransport', 'controlURL': '/upnp/service/AVTransport/Control', 'eventSubURL': '/upnp/service/AVTransport/Event', 'SCPDURL': '/upnp/service/des/avt.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:RenderingControl:1', 'serviceId': 'urn:upnp-org:serviceId:RenderingControl', 'controlURL': '/upnp/service/RenderingControl/Control', 'eventSubURL': '/upnp/service/RenderingControl/Event', 'SCPDURL': '/upnp/service/des/rcs.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:X-CTC_RemotePairing:1', 'serviceId': 'urn:upnp-org:serviceId:X-CTC_RemotePairing', 'controlURL': '/upnp/service/X-CTC_RemotePairing/Control', 'eventSubURL': '/upnp/service/X-CTC_RemotePairing/Event', 'SCPDURL': '/upnp/service/des/X-CTC_RemotePairing.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:X-CTC_RemoteControl:1', 'serviceId': 'urn:upnp-org:serviceId:X-CTC_RemoteControl', 'controlURL': '/upnp/service/X-CTC_RemoteControl/Control', 'eventSubURL': '/upnp/service/X-CTC_RemoteControl/Event', 'SCPDURL': '/upnp/service/des/X-CTC_RemoteControl.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:X-CTC_OpenApp:1', 'serviceId': 'urn:upnp-org:serviceId:X-CTC_OpenApp', 'controlURL': '/upnp/service/X-CTC_OpenApp/Control', 'eventSubURL': '/upnp/service/X-CTC_OpenApp/Event', 'SCPDURL': '/upnp/service/des/X-CTC_OpenApp.xml'}]}}, ssdp_location='http://192.168.1.159:8081/xml/xctc.xml', ssdp_nt='upnp:rootdevice', ssdp_udn='uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', ssdp_ext=None, ssdp_server='Linux/2.6 UPnP/1.1 zss/1.0', ssdp_headers={'HOST': '239.255.255.250:1900', 'CACHE-CONTROL': 'max-age=120', 'BOOTID.UPNP.ORG': '1', 'CONFIGID.UPNP.ORG': '1', 'LOCATION': 'http://192.168.1.159:8081/xml/xctc.xml', 'NT': 'upnp:rootdevice', 'NTS': 'ssdp:alive', 'SERVER': 'Linux/2.6 UPnP/1.1 zss/1.0', 'USN': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5::upnp:rootdevice', '_host': '192.168.1.159', '_udn': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', '_location_original': 'http://192.168.1.159:8081/xml/xctc.xml', 'location': 'http://192.168.1.159:8081/xml/xctc.xml', '_timestamp': datetime.datetime(2024, 8, 2, 13, 31, 36, 143526), '_remote_addr': ('192.168.1.159', 1900), '_port': 1900, '_local_addr': ('0.0.0.0', 1900), '_source': <SsdpSource.ADVERTISEMENT: 'advertisement'>}, ssdp_all_locations={'http://192.168.1.159:8081/xml/xctc.xml'}, x_homeassistant_matching_domains={'magentatv'})
2024-08-02 13:31:41.593 DEBUG (MainThread) [custom_components.magentatv] async_step_ssdp SsdpServiceInfo(ssdp_usn='uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', ssdp_st='uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', upnp={'UDN': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', 'friendlyName': 'Hctmagentatv', 'deviceType': 'urn:schemas-upnp-org:device:MediaRenderer:1', 'manufacturer': 'Huawei Technologies Co.,Ltd', 'modelName': 'MR401B_ACN', 'modelNumber': 'R01A5', 'productVersionNumber': '" 1243 "', 'productType': 'stb', 'serialNumber': None, 'X_wakeOnLan': '0', 'X_DLNADOC': 'DMR-1.50', 'X_DLNACAP': None, 'serviceList': {'service': [{'serviceType': 'urn:schemas-upnp-org:service:ConnectionManager:1', 'serviceId': 'urn:upnp-org:serviceId:ConnectionManager', 'controlURL': '/upnp/service/ConnectionManager/Control', 'eventSubURL': '/upnp/service/ConnectionManager/Event', 'SCPDURL': '/upnp/service/des/cms.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:AVTransport:1', 'serviceId': 'urn:upnp-org:serviceId:AVTransport', 'controlURL': '/upnp/service/AVTransport/Control', 'eventSubURL': '/upnp/service/AVTransport/Event', 'SCPDURL': '/upnp/service/des/avt.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:RenderingControl:1', 'serviceId': 'urn:upnp-org:serviceId:RenderingControl', 'controlURL': '/upnp/service/RenderingControl/Control', 'eventSubURL': '/upnp/service/RenderingControl/Event', 'SCPDURL': '/upnp/service/des/rcs.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:X-CTC_RemotePairing:1', 'serviceId': 'urn:upnp-org:serviceId:X-CTC_RemotePairing', 'controlURL': '/upnp/service/X-CTC_RemotePairing/Control', 'eventSubURL': '/upnp/service/X-CTC_RemotePairing/Event', 'SCPDURL': '/upnp/service/des/X-CTC_RemotePairing.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:X-CTC_RemoteControl:1', 'serviceId': 'urn:upnp-org:serviceId:X-CTC_RemoteControl', 'controlURL': '/upnp/service/X-CTC_RemoteControl/Control', 'eventSubURL': '/upnp/service/X-CTC_RemoteControl/Event', 'SCPDURL': '/upnp/service/des/X-CTC_RemoteControl.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:X-CTC_OpenApp:1', 'serviceId': 'urn:upnp-org:serviceId:X-CTC_OpenApp', 'controlURL': '/upnp/service/X-CTC_OpenApp/Control', 'eventSubURL': '/upnp/service/X-CTC_OpenApp/Event', 'SCPDURL': '/upnp/service/des/X-CTC_OpenApp.xml'}]}}, ssdp_location='http://192.168.1.159:8081/xml/xctc.xml', ssdp_nt='uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', ssdp_udn='uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', ssdp_ext=None, ssdp_server='Linux/2.6 UPnP/1.1 zss/1.0', ssdp_headers={'HOST': '239.255.255.250:1900', 'CACHE-CONTROL': 'max-age=120', 'BOOTID.UPNP.ORG': '1', 'CONFIGID.UPNP.ORG': '1', 'LOCATION': 'http://192.168.1.159:8081/xml/xctc.xml', 'NT': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', 'NTS': 'ssdp:alive', 'SERVER': 'Linux/2.6 UPnP/1.1 zss/1.0', 'USN': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', '_host': '192.168.1.159', '_udn': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', '_location_original': 'http://192.168.1.159:8081/xml/xctc.xml', 'location': 'http://192.168.1.159:8081/xml/xctc.xml', '_timestamp': datetime.datetime(2024, 8, 2, 13, 31, 36, 146589), '_remote_addr': ('192.168.1.159', 1900), '_port': 1900, '_local_addr': ('0.0.0.0', 1900), '_source': <SsdpSource.ADVERTISEMENT: 'advertisement'>}, ssdp_all_locations={'http://192.168.1.159:8081/xml/xctc.xml'}, x_homeassistant_matching_domains={'magentatv'})
2024-08-02 13:31:41.593 DEBUG (MainThread) [custom_components.magentatv] async_step_ssdp SsdpServiceInfo(ssdp_usn='uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5::urn:schemas-upnp-org:device:MediaRenderer:1', ssdp_st='urn:schemas-upnp-org:device:MediaRenderer:1', upnp={'UDN': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', 'friendlyName': 'Hctmagentatv', 'deviceType': 'urn:schemas-upnp-org:device:MediaRenderer:1', 'manufacturer': 'Huawei Technologies Co.,Ltd', 'modelName': 'MR401B_ACN', 'modelNumber': 'R01A5', 'productVersionNumber': '" 1243 "', 'productType': 'stb', 'serialNumber': None, 'X_wakeOnLan': '0', 'X_DLNADOC': 'DMR-1.50', 'X_DLNACAP': None, 'serviceList': {'service': [{'serviceType': 'urn:schemas-upnp-org:service:ConnectionManager:1', 'serviceId': 'urn:upnp-org:serviceId:ConnectionManager', 'controlURL': '/upnp/service/ConnectionManager/Control', 'eventSubURL': '/upnp/service/ConnectionManager/Event', 'SCPDURL': '/upnp/service/des/cms.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:AVTransport:1', 'serviceId': 'urn:upnp-org:serviceId:AVTransport', 'controlURL': '/upnp/service/AVTransport/Control', 'eventSubURL': '/upnp/service/AVTransport/Event', 'SCPDURL': '/upnp/service/des/avt.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:RenderingControl:1', 'serviceId': 'urn:upnp-org:serviceId:RenderingControl', 'controlURL': '/upnp/service/RenderingControl/Control', 'eventSubURL': '/upnp/service/RenderingControl/Event', 'SCPDURL': '/upnp/service/des/rcs.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:X-CTC_RemotePairing:1', 'serviceId': 'urn:upnp-org:serviceId:X-CTC_RemotePairing', 'controlURL': '/upnp/service/X-CTC_RemotePairing/Control', 'eventSubURL': '/upnp/service/X-CTC_RemotePairing/Event', 'SCPDURL': '/upnp/service/des/X-CTC_RemotePairing.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:X-CTC_RemoteControl:1', 'serviceId': 'urn:upnp-org:serviceId:X-CTC_RemoteControl', 'controlURL': '/upnp/service/X-CTC_RemoteControl/Control', 'eventSubURL': '/upnp/service/X-CTC_RemoteControl/Event', 'SCPDURL': '/upnp/service/des/X-CTC_RemoteControl.xml'}, {'serviceType': 'urn:schemas-upnp-org:service:X-CTC_OpenApp:1', 'serviceId': 'urn:upnp-org:serviceId:X-CTC_OpenApp', 'controlURL': '/upnp/service/X-CTC_OpenApp/Control', 'eventSubURL': '/upnp/service/X-CTC_OpenApp/Event', 'SCPDURL': '/upnp/service/des/X-CTC_OpenApp.xml'}]}}, ssdp_location='http://192.168.1.159:8081/xml/xctc.xml', ssdp_nt='urn:schemas-upnp-org:device:MediaRenderer:1', ssdp_udn='uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', ssdp_ext=None, ssdp_server='Linux/2.6 UPnP/1.1 zss/1.0', ssdp_headers={'HOST': '239.255.255.250:1900', 'CACHE-CONTROL': 'max-age=120', 'BOOTID.UPNP.ORG': '1', 'CONFIGID.UPNP.ORG': '1', 'LOCATION': 'http://192.168.1.159:8081/xml/xctc.xml', 'NT': 'urn:schemas-upnp-org:device:MediaRenderer:1', 'NTS': 'ssdp:alive', 'SERVER': 'Linux/2.6 UPnP/1.1 zss/1.0', 'USN': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5::urn:schemas-upnp-org:device:MediaRenderer:1', '_host': '192.168.1.159', '_udn': 'uuid:8ef14b6e-86b2-5397-8dda-AC6FBBB73EB5', '_location_original': 'http://192.168.1.159:8081/xml/xctc.xml', 'location': 'http://192.168.1.159:8081/xml/xctc.xml', '_timestamp': datetime.datetime(2024, 8, 2, 13, 31, 36, 147078), '_remote_addr': ('192.168.1.159', 1900), '_port': 1900, '_local_addr': ('0.0.0.0', 1900), '_source': <SsdpSource.ADVERTISEMENT: 'advertisement'>}, ssdp_all_locations={'http://192.168.1.159:8081/xml/xctc.xml'}, x_homeassistant_matching_domains={'magentatv'})
2024-08-02 13:31:41.611 WARNING (MainThread) [homeassistant.components.automation.sommermodus] Sommermodus: Already running
2024-08-02 13:31:48.984 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:31:58.984 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:32:08.985 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:32:18.986 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:32:28.988 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:32:38.988 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:32:48.989 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:32:58.991 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:33:08.993 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.magentatvlivingroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 944, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1296, in async_device_update
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'
2024-08-02 13:33:18.710 INFO (MainThread) [custom_components.magentatv] MagentaTV setup entry
2024-08-02 13:33:18.712 ERROR (MainThread) [homeassistant.components.media_player] Error adding entity media_player.magentatvlivingroom for domain media_player with platform magentatv
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 598, in _async_add_entities
    await coro
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 912, in _async_add_entity
    await entity.add_to_platform_finish()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1361, in add_to_platform_finish
    await self.async_added_to_hass()
  File "/config/custom_components/magentatv/media_player.py", line 172, in async_added_to_hass
    await self.async_update()
  File "/config/custom_components/magentatv/media_player.py", line 182, in async_update
    await self._client.async_pair()
  File "/config/custom_components/magentatv/api/client.py", line 97, in async_pair
    await self._register_for_events()
  File "/config/custom_components/magentatv/api/client.py", line 81, in _register_for_events
    self._event_registration_id = await self._notify_server._async_subscribe_to_service(
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 102, in _async_subscribe_to_service
    sid = await self._async_subscribe(target, service)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/magentatv/api/notify_server.py", line 134, in _async_subscribe
    response = await self._requester.async_http_request(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AiohttpRequester.async_http_request() got an unexpected keyword argument 'method'

Diagnostics dump

No response

Xyaren commented 1 month ago

Hi! Thank you for your feedback. This issue is most likely already fixed with version 0.2.7 . Could you please update to the latest version and check if the issue persists ?

hctom commented 1 month ago

Thanks for the reply - I totally overlooked the pre-releases, now updated to 0.3.0 now and all is working again. So this issue should be resolved.