dahlb / ha_blueair

Home Assistant Integration for Blueair Class Filters
MIT License
29 stars 6 forks source link

Issue with Service Fan: Turn on using HA 2023.12.1 #52

Closed amorabito closed 9 months ago

amorabito commented 10 months ago

After upgrading HA to 2023.12.1 image seeing issue with Service Fan: Turn on with Blueair filter. Fan: Turn off and Fan: Toggle seem to work fine.

Logger: homeassistant.components.websocket_api.http.connection
Source: components/websocket_api/commands.py:238
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 1:28:49 AM (3 occurrences)
Last logged: 1:30:14 PM

[140469330725184] BlueairAwsFan.async_turn_on() takes from 1 to 2 positional arguments but 3 were given
[140469176831936] BlueairAwsFan.async_turn_on() takes from 1 to 2 positional arguments but 3 were given
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 238, in handle_call_service
    response = await hass.services.async_call(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2067, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2104, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 272, in handle_service
    return await service.entity_service_call(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 878, in entity_service_call
    single_response = await _handle_entity_call(
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 948, in _handle_entity_call
    result = await task
             ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/fan/__init__.py", line 305, in async_handle_turn_on_service
    await self.async_turn_on(percentage, preset_mode, **kwargs)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: BlueairAwsFan.async_turn_on() takes from 1 to 2 positional arguments but 3 were given
dahlb commented 9 months ago

I haven't been able to confirm myself, but I think https://github.com/dahlb/ha_blueair/commit/63db8fc2fa6287eef99807b658dc9fb147384150 will fix this issue

amorabito commented 9 months ago

@dahlb thank you sir. Updated to 1.7.5 and seems to be resolved!