diff --git a/.gitmodules b/.gitmodules index f33d9430f54..a627e522d8f 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,6 +1,3 @@ -[submodule "homeassistant/external/pywemo"] - path = homeassistant/external/pywemo - url = https://github.com/balloob/pywemo.git [submodule "homeassistant/external/noop"] path = homeassistant/external/noop url = https://github.com/balloob/noop.git diff --git a/homeassistant/components/switch/wemo.py b/homeassistant/components/switch/wemo.py index eb55e0662b7..33f5f03799b 100644 --- a/homeassistant/components/switch/wemo.py +++ b/homeassistant/components/switch/wemo.py @@ -12,17 +12,8 @@ from homeassistant.components.switch import SwitchDevice # pylint: disable=unused-argument def setup_platform(hass, config, add_devices_callback, discovery_info=None): """ Find and return WeMo switches. """ - try: - # pylint: disable=no-name-in-module, import-error - import homeassistant.external.pywemo.pywemo as pywemo - import homeassistant.external.pywemo.pywemo.discovery as discovery - except ImportError: - logging.getLogger(__name__).exception(( - "Failed to import pywemo. " - "Did you maybe not run `git submodule init` " - "and `git submodule update`?")) - - return + import pywemo + import pywemo.discovery as discovery if discovery_info is not None: device = discovery.device_from_description(discovery_info) diff --git a/homeassistant/external/pywemo b/homeassistant/external/pywemo deleted file mode 160000 index ca94e41faa4..00000000000 --- a/homeassistant/external/pywemo +++ /dev/null @@ -1 +0,0 @@ -Subproject commit ca94e41faa48c783f600a2efd550c6b7dae01b0d diff --git a/requirements.txt b/requirements.txt index e601614bb96..e910ffba95f 100644 --- a/requirements.txt +++ b/requirements.txt @@ -82,3 +82,6 @@ pynetgear>=0.1 # Netdisco (discovery) netdisco>=0.1 + +# Wemo (switch.wemo) +pywemo>=0.1