Tasshack / dreame-vacuum

Home Assistant integration for Dreame robot vacuums with map support
https://community.home-assistant.io/t/custom-component-dreame-vacuum
MIT License
888 stars 111 forks source link

Send request map failed on start/reboot #667

Closed kbullet closed 3 months ago

kbullet commented 3 months ago

Describe the bug Not sure if its affecting other people but for me after updating to the latest beta v2.0.0b16 each time I start/reboot hass I'm getting the error below which causes the integration to fail/not load properly. Though the workaround I have found is to manually reload the integration after the error, then it works just fine.

To Reproduce hass on start/restart will throw the Send request map failed: Unable to discover the device over cloud error

Expected behavior Integration should start normally without needing to be reloaded manually

Additional Information (please complete the following information)

2024-08-13 21:55:41.119 WARNING (SyncWorker_1) [custom_components.dreame_vacuum.dreame.map] Send request map failed: Unable to discover the device over cloud 2024-08-13 21:55:41.125 ERROR (Thread-12 (_api_task)) [root] Uncaught thread exception Traceback (most recent call last): File "/usr/local/lib/python3.12/threading.py", line 1073, in _bootstrap_inner self.run() File "/usr/local/lib/python3.12/threading.py", line 1010, in run self._target(*self._args, **self._kwargs) File "/config/custom_components/dreame_vacuum/dreame/protocol.py", line 112, in _api_task item[0](self._api_call(item[1], item[2], item[3])) File "/config/custom_components/dreame_vacuum/dreame/protocol.py", line 388, in lambda api_response: callback( ^^^^^^^^^ File "/config/custom_components/dreame_vacuum/dreame/protocol.py", line 1206, in cloud_callback raise DeviceException("Unable to discover the device over cloud") from None custom_components.dreame_vacuum.dreame.exceptions.DeviceException: Unable to discover the device over cloud

Tasshack commented 3 months ago

I am sure this is not related to the changes in v2.0.0b16 because there aren't any related to the cloud communication so I need more information for confirming the issue is not related to your local network, ISP or DNS.

kbullet commented 3 months ago

Ah yes think you're spot on must have been some funky connection issue from on my side or Dreame's SG servers (now to think of it couple of times I could not get the map to load even on Dreame's app). I can no longer reproduce this error now as I did last couple of days. Thanks for the prompt response and the amazing work!