Traceback (most recent call last):


 "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 159, in _async_setup_platform

await asyncio.wait_for(asyncio.shield(task), SLOW_SETUP_MAX_WAIT)


 "/usr/local/lib/python3.7/asyncio/tasks.py", line 442, in wait_for

return fut.result()


 "/usr/local/lib/python3.7/concurrent/futures/thread.py", line 57, in run

result = self.fn(*self.args, **self.kwargs)


 "/usr/src/homeassistant/homeassistant/components/duke_energy/sensor.py", line 34, in setup_platform

add_entities([DukeEnergyMeter(meter) for meter in duke.get_meters()])


 "/usr/local/lib/python3.7/site-packages/pydukeenergy/api.py", line 52, in get_meters

self._get_meters()


 "/usr/local/lib/python3.7/site-packages/pydukeenergy/api.py", line 160, in _get_meters

meter_data = json.loads(soup.find("duke-dropdown", {"id": "usageAnalysisMeter"})["items"])
TypeError: 'NoneType' object is not subscriptable

Traceback (most recent call last):


 "/Users/user/.virtualenvs/application/lib/python2.7/site-packages/django/utils/autoreload.py", line 226, in wrapper

fn(*args, **kwargs)


 "/Users/user/.virtualenvs/application/lib/python2.7/site-packages/django/core/management/commands/runserver.py", line 116, in inner_run

self.check(display_num_errors=True)


 "/Users/user/.virtualenvs/application/lib/python2.7/site-packages/django/core/management/base.py", line 426, in check

include_deployment_checks=include_deployment_checks,


 "/Users/user/.virtualenvs/application/lib/python2.7/site-packages/django/core/checks/registry.py", line 75, in run_checks

new_errors = check(app_configs=app_configs)


 "/Users/user/Code/django-tenant-schemas/tenant_schemas/apps.py", line 22, in best_practice

for config in app_configs
TypeError: 'NoneType' object is not iterable
