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

Basic and Basic2 switches unavailable after update to v3 #817

Closed
roelof-47 opened this issue May 4, 2022 · 9 comments
Closed

Basic and Basic2 switches unavailable after update to v3 #817

roelof-47 opened this issue May 4, 2022 · 9 comments
Labels
question Further information is requested

Comments

@roelof-47
Copy link

roelof-47 commented May 4, 2022

This is to reopen #809. The reported issue has not been solved.
config_entry-sonoff-807f1440c52b59e2675ad6451304e34b.json.txt

After the update one of the error messages has been solved, but the following error message still exists.
I send you also the download of the diagnostics.

Logger: homeassistant
Source: custom_components/sonoff/core/ewelink/__init__.py:44
Integration: Sonoff ([documentation](https://github.com/AlexxIT/SonoffLAN), [issues](https://github.com/AlexxIT/SonoffLAN/issues))
First occurred: 20:54:54 (1 occurrences)
Last logged: 20:54:54
Error doing job: Task exception was never retrieved

Traceback (most recent call last):
  File "/config/custom_components/sonoff/__init__.py", line 201, in internal_normal_setup
    await internal_cache_setup(hass, entry, devices)
  File "/config/custom_components/sonoff/__init__.py", line 222, in internal_cache_setup
    registry.setup_devices(devices)
  File "/config/custom_components/sonoff/core/ewelink/__init__.py", line 44, in setup_devices
    _LOGGER.debug(f"{deviceid} UIID {uiid:04} | %s", device["params"])
KeyError: 'params'
@AlexxIT AlexxIT added the question Further information is requested label May 5, 2022
@AlexxIT
Copy link
Owner

AlexxIT commented May 5, 2022

Have you installed master version? Check this code there

_LOGGER.warning(f"{did} !! can't setup device", exc_info=e)

@roelof-47
Copy link
Author

Checked line 54 after download master.
Line content is identical.

@AlexxIT
Copy link
Owner

AlexxIT commented May 5, 2022

So _LOGGER.debug... can't be on line 44. It's on line 45. You showing error from old version

@roelof-47
Copy link
Author

roelof-47 commented May 5, 2022

I repeated the procedure: load master, download diagnostics...
This is the result:

Error message from logbook

Logger: homeassistant
Source: custom_components/sonoff/core/ewelink/__init__.py:44
Integration: Sonoff ([documentation](https://github.com/AlexxIT/SonoffLAN), [issues](https://github.com/AlexxIT/SonoffLAN/issues))
First occurred: 11:30:46 (1 occurrences)
Last logged: 11:30:46
Error doing job: Task exception was never retrieved

Traceback (most recent call last):
  File "/config/custom_components/sonoff/__init__.py", line 201, in internal_normal_setup
    await internal_cache_setup(hass, entry, devices)
  File "/config/custom_components/sonoff/__init__.py", line 222, in internal_cache_setup
    registry.setup_devices(devices)
  File "/config/custom_components/sonoff/core/ewelink/__init__.py", line 44, in setup_devices
    _LOGGER.debug(f"{deviceid} UIID {uiid:04} | %s", device["params"])
KeyError: 'params'

config_entry-sonoff-807f1440c52b59e2675ad6451304e34b.json.txt

@roelof-47
Copy link
Author

To be complete:
Of course, I restarted the system before creating the files

@roelof-47
Copy link
Author

Surprise.
I did download the master version again this afternoon.
This message appear after restart. It includes the line 45

Logger: custom_components.sonoff.core.ewelink
Source: custom_components/sonoff/core/ewelink/init.py:45
Integration: Sonoff (documentation, issues)
First occurred: 16:29:25 (1 occurrences)
Last logged: 16:29:25
10007daa68 !! can't setup device

Traceback (most recent call last):
File "/config/custom_components/sonoff/core/ewelink/init.py", line 45, in setup_devices
_LOGGER.debug(f"{did} UIID {uiid:04} | %s", device["params"])
KeyError: 'params'

@roelof-47
Copy link
Author

Herewith the latest version of the diagnostics

config_entry-sonoff-807f1440c52b59e2675ad6451304e34b.json.txt

@roelof-47
Copy link
Author

The switches are actif again. I think the problem is solved !!!
Thank you Alex for your help and your actions.

@AlexxIT
Copy link
Owner

AlexxIT commented May 5, 2022

You will continue receive this warning because problem with device should be solved. But integration will work with other devices without problems.

@AlexxIT AlexxIT closed this as completed May 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants