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

Error setting up entry Broadlink for broadlink #47694

Closed
Arvics opened this issue Mar 9, 2021 · 8 comments · Fixed by #47779
Closed

Error setting up entry Broadlink for broadlink #47694

Arvics opened this issue Mar 9, 2021 · 8 comments · Fixed by #47779

Comments

@Arvics
Copy link

Arvics commented Mar 9, 2021

The problem

Every time after core upgrade I will get error:
'Error setting up entry Broadlink for broadlink'

I using RM4 pro.

What is version of Home Assistant Core has the issue?

core-2021.3.3

What was the last working version of Home Assistant Core?

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Broadlink

Link to integration documentation on our website

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

Example YAML snippet

# Put your YAML below this line

Anything in the logs that might be useful for us?

# Put your logs below this line
Logger: homeassistant.config_entries
Source: components/broadlink/updater.py:24
First occurred: 9:31:39 (1 occurrences)
Last logged: 9:31:39

Error setting up entry Broadlink for broadlink
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 248, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/usr/src/homeassistant/homeassistant/components/broadlink/__init__.py", line 25, in async_setup_entry
    return await device.async_setup()
  File "/usr/src/homeassistant/homeassistant/components/broadlink/device.py", line 95, in async_setup
    update_manager = get_update_manager(self)
  File "/usr/src/homeassistant/homeassistant/components/broadlink/updater.py", line 24, in get_update_manager
    if device.api.model.startswith("RM mini"):
AttributeError: 'NoneType' object has no attribute 'startswith'
@probot-home-assistant
Copy link

Hey there @Danielhiversen, @felipediel, mind taking a look at this issue as its been labeled with an integration (broadlink) you are listed as a codeowner for? Thanks!
(message by CodeOwnersMention)

@robi59italy
Copy link

I had a similar problem with Broadlink 4 Mini and core 2021.3.1 and 2021.3.2
The broadlink is missing same command coming from HA. I have a sequence of command to switch on an heater and I'm always missing one or two
Back to core.2021.2.3 and it's ok.
I'm using Broadlink integration updated to last version.
I didn't find any info in the logs

@felipediel
Copy link
Contributor

@Arvics You forgot to re-patch your installation after updating Home Assistant.

@robi59italy We didn't change the Broadlink integration this year. Try to reposition the remote. If it doesn't work, relearn the codes with the alternative: True flag to improve the response rate.

@robi59italy
Copy link

@robi59italy We didn't change the Broadlink integration this year. Try to reposition the remote. If it doesn't work, relearn the codes with the alternative: True flag to improve the response rate.

I think it's not a problem of broadlink integration but coming from core assistant.... going back to old version solved everything.

I will try again to install 2021.3.3 and we will see

@Arvics
Copy link
Author

Arvics commented Mar 12, 2021

You forgot to re-patch your installation after updating Home Assistant.

@felipediel I apologize - I don't understand your comment. I'm not so good with programming .... Would you please explain more in details what I should do?

@felipediel
Copy link
Contributor

You used a patch to temporarily add support for your device while waiting for the release, right? When you update Home Assistant you need to patch your installation again. It's like a new installation, the patch is not persistent.

  1. Open Home Assistant and install "SSH & Web Terminal" add-on
  2. Disable Protection mode
  3. Click "Terminal" on the sidebar and install the patch. You can take my master branch for now:
docker exec -it homeassistant /bin/bash
pip3 install git+https://github.com/felipediel/python-broadlink.git --force-reinstall --no-deps
  1. Restart the server.

@Arvics
Copy link
Author

Arvics commented Mar 13, 2021

You used a patch to temporarily add support for your device while waiting for the release, right? When you update Home Assistant you need to patch your installation again. It's like a new installation, the patch is not persistent.

  1. Open Home Assistant and install "SSH & Web Terminal" add-on
  2. Disable Protection mode
  3. Click "Terminal" on the sidebar and install the patch. You can take my master branch for now:
docker exec -it homeassistant /bin/bash
pip3 install git+https://github.com/felipediel/python-broadlink.git --force-reinstall --no-deps
  1. Restart the server.

Thank you so much!

Cheers!

@felipediel
Copy link
Contributor

felipediel commented Mar 13, 2021

You're welcome!

@github-actions github-actions bot locked and limited conversation to collaborators Apr 12, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants