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

throw PlatformNotReady if unable to connect #22515

Merged
merged 1 commit into from Mar 29, 2019
Merged

throw PlatformNotReady if unable to connect #22515

merged 1 commit into from Mar 29, 2019

Conversation

aav7fl
Copy link
Contributor

@aav7fl aav7fl commented Mar 29, 2019

Throw PlatformNotReady for when the device disconnects, or when the Home Assistant is booting and the ADB server is not ready yet.

Description:

When HA is ready before my ADB server in my docker container, or if my device disconnects from the network temporarily, HA loses connection and requires a restart. Instead, I think it should throw a PlatformNotReady so it will retry it, and do it in a back-off manner.

I tested this on my own network and it fixed my problem. I think others should benefit from this too.

Checklist:

  • The code change is tested and works locally.
  • Local tests pass with tox. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.

If the code communicates with devices, web services, or third-party tools:

  • New dependencies are only imported inside functions that use them (example).

Throw `PlatformNotReady` for when the device disconnects, or when the Home Assistant is booting and the ADB server is not ready yet.
@ghost ghost added the in progress label Mar 29, 2019
Copy link
Member

@andrewsayre andrewsayre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! Can merge when build passes.

@rohankapoorcom rohankapoorcom merged commit 1050baa into home-assistant:dev Mar 29, 2019
@ghost ghost removed the in progress label Mar 29, 2019
@aav7fl aav7fl deleted the patch-1 branch March 29, 2019 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants