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

AttributeError did you mean 'rate_limit_reset' after restart #216

Open
TinyR0dent opened this issue Jan 23, 2025 · 5 comments
Open

AttributeError did you mean 'rate_limit_reset' after restart #216

TinyR0dent opened this issue Jan 23, 2025 · 5 comments

Comments

@TinyR0dent
Copy link

Describe the bug

I restarted my HAOS and the Govee integration "failed to set up" and the logs mention an attribute that needs to be renamed

Debug log

Logger: homeassistant.config_entries
Source: config_entries.py:640
First occurred: 01:04:00 (1 occurrences)
Last logged: 01:04:00

Error setting up entry govee for govee
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 640, in __async_setup_with_context
    result = await component.async_setup_entry(hass, self)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/govee/__init__.py", line 67, in async_setup_entry
    await hub.rate_limit_delay()
          ^^^^^^^^^^^^^^^^^^^^
AttributeError: 'Govee' object has no attribute 'rate_limit_delay'. Did you mean: 'rate_limit_reset'?

@UncleLeoTheDad
Copy link

I am getting the same

@chuck2941
Copy link

I also get the same message.
I come from IObroker, where the adapter has always worked, you don't need an API there either.

@Seagull1901
Copy link

Same happening here

@TinyR0dent
Copy link
Author

TinyR0dent commented Jan 25, 2025

@UncleLeoTheDad
@chuck2941
@Seagull1901

I'm tempted to push a fix myself, but it's very easy to repair yourself.

If you have file_editor or Studio Code Server Add On for HAOS go to 'custom_components/govee/init.py' (with the underscrores, it defaults to using that to make the text bold in here) and the error is on line 67, just change it to this :

await hub.rate_limit_reset()

then just restart your Home Assistant and mine was working again.

@TinyR0dent
Copy link
Author

I'll leave it open until it's merged incase anyone has the same issue and wants the fix

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

No branches or pull requests

4 participants