Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fan on command doesn't work #47

Closed
Automated-House opened this issue May 1, 2024 · 3 comments · Fixed by #48
Closed

Fan on command doesn't work #47

Automated-House opened this issue May 1, 2024 · 3 comments · Fixed by #48

Comments

@Automated-House
Copy link

Turning an IR fan on from HA doesn't work. The off command does.

Logger: homeassistant.components.websocket_api.http.connection
Source: components/websocket_api/commands.py:239
integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 9:48:12 PM (1 occurrences)
Last logged: 9:48:12 PM

[545442487360] SwitchBotRemoteFan.async_turn_on() takes 1 positional argument but 3 were given
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 239, in handle_call_service
response = await hass.services.async_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2543, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2580, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 971, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1043, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/fan/init.py", line 333, in async_handle_turn_on_service
await self.async_turn_on(percentage, preset_mode, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: SwitchBotRemoteFan.async_turn_on() takes 1 positional argument but 3 were given

@KiraPC
Copy link
Owner

KiraPC commented May 1, 2024

@Automated-House Hello,

When this issue occurs?

I guess this is related in the way the integration is called.

What HomeAssistant version do you have?

@Automated-House
Copy link
Author

This occurs when turning the fan entity on
image

I'm on 2024.4.4

@KiraPC KiraPC closed this as completed in #48 May 3, 2024
KiraPC added a commit that referenced this issue May 3, 2024
@KiraPC
Copy link
Owner

KiraPC commented May 3, 2024

Fix released in 1.2.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants