Fix Roomba setup#34089
Conversation
|
There are merge conflicts. |
|
According to #34867, there seems to be some problem in the config flow that need to be fixed.
|
Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>
Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>
This reverts commit 471c283f75b207262a473f5d117604658b443425.
Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>
Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>
…ssistant into roomba_fix" This reverts commit 6cc5c4ac35fd9e885d6341921d50f1ea25e6f299, reversing changes made to 27027089919e55e589a2bd4e38f7e10b3488dcc6.
|
Please rebase on latest dev branch and solve the merge conflict. |
shenxn
left a comment
There was a problem hiding this comment.
There are some new fixes merged. Please rebase on latest dev branch.
|
|
||
| @property | ||
| def state(self): | ||
| def is_on(self): |
There was a problem hiding this comment.
This is already fixed in #35443. Do a rebase and this will be no longer needed.
| errors = {"base": "cannot_disconnect"} | ||
| except Exception as error: # pylint: disable=broad-except | ||
| _LOGGER.error("An unknown error occurred: %s", error) | ||
| errors = {"base": "unknown"} |
| await hass.async_add_executor_job(roomba.disconnect) | ||
| while roomba.roomba_connected: | ||
| await asyncio.sleep(1) | ||
| break |
There was a problem hiding this comment.
I think the problem here is that you are using while loop and break in the first iteration. You should either use if statement if you just want to sleep for 1 second if it is still connected, or you can remove the break so the while loop will wait until it's disconnected, or you just remove the loop and it will wait for 1 second anyway. If I understand your comment correctly, you want to wait until disconnected and then wait for another second to make sure the reconnect works well. Then you'll need to delete the break statement and add another sleep outside the while loop.
|
There hasn't been any activity on this pull request recently. This pull request has been automatically marked as stale because of that and will be closed if no further activity occurs within 7 days. |
Proposed change
Modification made following the merger of the PR #33302
Type of change
Example entry for
configuration.yaml:# Example configuration.yamlAdditional information
Checklist
black --fast homeassistant tests)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest.requirements_all.txt.Updated by running
python3 -m script.gen_requirements_all..coveragerc.The integration reached or maintains the following Integration Quality Scale: