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

Switchmate error on 2024.1 #107086

Closed
valkjsaaa opened this issue Jan 4, 2024 · 3 comments · Fixed by #107097
Closed

Switchmate error on 2024.1 #107086

valkjsaaa opened this issue Jan 4, 2024 · 3 comments · Fixed by #107097

Comments

@valkjsaaa
Copy link
Contributor

The problem

Switchmate switches becomes unavailable

What version of Home Assistant Core has the issue?

core-2024.1.0

What was the last working version of Home Assistant Core?

core-2023?

What type of installation are you running?

Home Assistant Container

Integration causing the issue

Switchmate

Link to integration documentation on our website

https://www.home-assistant.io/integrations/switchmate/

Diagnostics information

N/A

Example YAML snippet

switch:
  - platform: switchmate
    mac: "cb:25:0b......"

Anything in the logs that might be useful for us?

Logger: homeassistant.components.switch
Source: helpers/entity_platform.py:573
Integration: Switch ([documentation](https://www.home-assistant.io/integrations/switch), [issues](https://github.com/home-assistant/core/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+switch%22))
First occurred: 2:33:58 AM (3 occurrences)
Last logged: 2:33:58 AM

switchmate: Error on device update!
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 573, in _async_add_entity
    await entity.async_device_update(warning=False)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1212, in async_device_update
    await self.async_update()
  File "/usr/src/homeassistant/homeassistant/components/switchmate/switch.py", line 71, in async_update
    await self._device.update()
  File "/usr/local/lib/python3.11/site-packages/switchmate/__init__.py", line 93, in update
    return await self._communicate()
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/switchmate/__init__.py", line 68, in _communicate
    ) and not await self._connect():
              ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/switchmate/__init__.py", line 35, in _connect
    await self._device.connect()
  File "/usr/local/lib/python3.11/site-packages/habluetooth/wrappers.py", line 273, in connect
    wrapped_backend = self._async_get_best_available_backend_and_device(manager)
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/habluetooth/wrappers.py", line 341, in _async_get_best_available_backend_and_device
    devices = manager.async_scanner_devices_by_address(self.__address, True)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: Argument 'address' has incorrect type (expected str, got NodeStrClass)

Additional information

No response

@home-assistant
Copy link

home-assistant bot commented Jan 4, 2024

Hey there @home-assistant/core, mind taking a look at this issue as it has been labeled with an integration (switch) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of switch can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign switch Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


switch documentation
switch source
(message by IssueLinks)

@home-assistant
Copy link

home-assistant bot commented Jan 4, 2024

Hey there @Danielhiversen, @qiz-li, mind taking a look at this issue as it has been labeled with an integration (switchmate) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of switchmate can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign switchmate Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


switchmate documentation
switchmate source
(message by IssueLinks)

@home-assistant
Copy link

home-assistant bot commented Jan 4, 2024

Hey there @bdraco, mind taking a look at this issue as it has been labeled with an integration (bluetooth) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of bluetooth can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign bluetooth Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


bluetooth documentation
bluetooth source
(message by IssueLinks)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.