load cleanups (#23112)

* load cleanups

* Remove unused methods

* Allow importing requirements at the top of a file

* Fix test

* Lint

* Install reqs ASAP when loading platforms
This commit is contained in:
Paulus Schoutsen 2019-04-15 16:45:46 -07:00 committed by GitHub
parent 4d080f8b17
commit 6a2da9f9a5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 64 additions and 146 deletions

View file

@ -3,6 +3,7 @@ import asyncio
import json
import os
from aiohue.discovery import discover_nupnp
import async_timeout
import voluptuous as vol
@ -57,8 +58,6 @@ class HueFlowHandler(config_entries.ConfigFlow):
async def async_step_init(self, user_input=None):
"""Handle a flow start."""
from aiohue.discovery import discover_nupnp
if user_input is not None:
self.host = user_input['host']
return await self.async_step_link()