Thank you so much for your time to respond and the detailed instructions. I tried all of the options you listed above:
- HA 56.2 with current dlink.py
- HA 56.2 with dlink.py from 52.1
- HA 52.1 with current dlink.py
- HA 52.1 with dlink.py from 52.1
- HASSIO 56.2
The results for all are identical and some switches show up, other switches don’t show up. To be clear, the same switches show up or don’t show up across all three combinations. The error is the same every time - copied the error below. I’m also following another thread which seems like a similar (the same) issue: https://community.home-assistant.io/t/d-link-motion-sensor-dch-s150/9850/17
Here is the error
2017-11-02 17:21:51 ERROR (MainThread) [homeassistant.components.switch] Error while setting up platform dlink
Traceback (most recent call last):
File “/srv/hass/hass_venv/lib/python3.4/site-packages/homeassistant/helpers/entity_component.py”, line 170, in _async_setup_platform
SLOW_SETUP_MAX_WAIT, loop=self.hass.loop)
File “/usr/lib/python3.4/asyncio/tasks.py”, line 372, in wait_for
return fut.result()
File “/usr/lib/python3.4/asyncio/futures.py”, line 277, in result
raise self._exception
File “/usr/lib/python3.4/concurrent/futures/thread.py”, line 54, in run
result = self.fn(*self.args, **self.kwargs)
File “/home/hass/.homeassistant/custom_components/switch/dlink.py”, line 450, in setup_platform
use_legacy_protocol))
File “/home/hass/.homeassistant/custom_components/switch/dlink.py”, line 77, in init
self.model_name = self.SOAPAction(Action=“GetDeviceSettings”, responseElement=“ModelName”, params = “”)
File “/home/hass/.homeassistant/custom_components/switch/dlink.py”, line 148, in SOAPAction
self.authenticated = self.auth()
File “/home/hass/.homeassistant/custom_components/switch/dlink.py”, line 325, in auth
response = urlopen(Request(self.url, payload, headers))
File “/usr/lib/python3.4/urllib/request.py”, line 153, in urlopen
return opener.open(url, data, timeout)
File “/usr/lib/python3.4/urllib/request.py”, line 461, in open
response = meth(req, response)
File “/usr/lib/python3.4/urllib/request.py”, line 571, in http_response
‘http’, request, response, code, msg, hdrs)
File “/usr/lib/python3.4/urllib/request.py”, line 499, in error
return self._call_chain(*args)
File “/usr/lib/python3.4/urllib/request.py”, line 433, in _call_chain
result = func(*args)
File “/usr/lib/python3.4/urllib/request.py”, line 579, in http_error_default
raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 500: Internal Server Error