Vera lights not reporting status correctly?

Btw is the switch that doesn’t work a different type than the others?

TI’ve added debugging to the pyvera library. It’s now merged into the development version of HA.

If you feel like trying the dev version of HA you can try it now - or wait for the next release next weekend.

One you have it, you need to add the following to your config.yaml

logger:
  logs:
      pyvera: debug
```

This will then trace the event data from vera. In my case this shows the following when I turn a switch on.

2017-04-29 16:48:34 DEBUG (Vera Poll Thread) [pyvera.subscribe] Poll returned
2017-04-29 16:48:34 DEBUG (Vera Poll Thread) [pyvera.subscribe] Event: Alcoves, state -1, {“altid”: “e2”, “id”: “17”, “subcategory”: “0”, “room”: “1”, “parent”: “15”, “commFailure”: “0”, “state”: “-1”, “comment”: “”, “status”: “1”}


state: -1 means NO_JOB - and status:1 means 'on'

If you can capture the traces we can see what's happening.
1 Like

they’re all the same switch, but the one that is having issues is a little older than the others. i’m hesitant to say it “doesn’t work” because it is working, just not as expected…and it is working every time, instantly, in vera itself.

switch that is having issues:
Version 6,3,40,3,25
Manufacturer GE/Jasco

switch that works most of the time:
Version 6,3,67,3,29
Manufacturer GE/Jasco

https://www.amazon.com/GE-Wireless-Lighting-Control-12722/dp/B0035YRCR2/ref=sr_1_2?ie=UTF8&qid=1493504758&sr=8-2&keywords=GE+z-wave+switch

i also have several appliance modules (both indoor and outdoor) that seem to work all the time, or at least most of the time. it’s just that one switch that seems to be consistently wonky.

i’d rather not mess around with the dev version of HA at this point, not til i get a little more experience working with it…but i have no problem waiting til next weekend. should i still create the issue on github now or wait til then?

I’ve raised it for you https://github.com/pavoni/pyvera/issues/51

Please update the issue when you have more data.

It’s easier for me to track issues in github than here (github sends me alerts)

Just to remind you that the trace code is now in the live version if you’re still having trouble.

i’ll try to spend some time this weekend playing around with it and get you a log. thanks!

1 Like

Im new to HA and I am trying to get Vera setup. I get an error saying that vera can’t be setup. I included the log, but I am not that savvy with scripts. I think it’s a problem with Vera API.

Please help

2017-09-12 01:58:45 ERROR (Thread-12) [homeassistant.components.vera] Error communicating with Vera API
Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/requests/packages/urllib3/connection.py”, line 141, in _new_conn
(self.host, self.port), self.timeout, **extra_kw)
File “/usr/local/lib/python3.5/dist-packages/requests/packages/urllib3/util/connection.py”, line 83, in create_connection
raise err
File “/usr/local/lib/python3.5/dist-packages/requests/packages/urllib3/util/connection.py”, line 73, in create_connection
sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/requests/packages/urllib3/connectionpool.py”, line 600, in urlopen
chunked=chunked)
File “/usr/local/lib/python3.5/dist-packages/requests/packages/urllib3/connectionpool.py”, line 356, in _make_request
conn.request(method, url, **httplib_request_kw)
File “/usr/lib/python3.5/http/client.py”, line 1106, in request
self._send_request(method, url, body, headers)
File “/usr/lib/python3.5/http/client.py”, line 1151, in _send_request
self.endheaders(body)
File “/usr/lib/python3.5/http/client.py”, line 1102, in endheaders
self._send_output(message_body)
File “/usr/lib/python3.5/http/client.py”, line 934, in _send_output
self.send(msg)
File “/usr/lib/python3.5/http/client.py”, line 877, in send
self.connect()
File “/usr/local/lib/python3.5/dist-packages/requests/packages/urllib3/connection.py”, line 166, in connect
conn = self._new_conn()
File “/usr/local/lib/python3.5/dist-packages/requests/packages/urllib3/connection.py”, line 150, in _new_conn
self, “Failed to establish a new connection: %s” % e)
requests.packages.urllib3.exceptions.NewConnectionError: <requests.packages.urllib3.connection.HTTPConnection object at 0x7fb35d8c5e10>: Failed to establish a new connection: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/requests/adapters.py”, line 438, in send
timeout=timeout
File “/usr/local/lib/python3.5/dist-packages/requests/packages/urllib3/connectionpool.py”, line 649, in urlopen
_stacktrace=sys.exc_info()[2])
File “/usr/local/lib/python3.5/dist-packages/requests/packages/urllib3/util/retry.py”, line 388, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
requests.packages.urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host=‘192.168.1.3’, port=3480): Max retries exceeded with url: //data_request?id=sdata (Caused by NewConnectionError(’<requests.packages.urllib3.connection.HTTPConnection object at 0x7fb35d8c5e10>: Failed to establish a new connection: [Errno 111] Connection refused’,))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/vera.py”, line 80, in setup
all_devices = VERA_CONTROLLER.get_devices()
File “/home/yusef/.homeassistant/deps/lib/python3.5/site-packages/pyvera/init.py”, line 103, in get_devices
self.get_simple_devices_info()
File “/home/yusef/.homeassistant/deps/lib/python3.5/site-packages/pyvera/init.py”, line 76, in get_simple_devices_info
j = self.data_request({‘id’: ‘sdata’}).json()
File “/home/yusef/.homeassistant/deps/lib/python3.5/site-packages/pyvera/init.py”, line 72, in data_request
return requests.get(request_url, timeout=timeout, params=payload)
File “/usr/local/lib/python3.5/dist-packages/requests/api.py”, line 72, in get
return request(‘get’, url, params=params, **kwargs)
File “/usr/local/lib/python3.5/dist-packages/requests/api.py”, line 58, in request
return session.request(method=method, url=url, **kwargs)
File “/usr/local/lib/python3.5/dist-packages/requests/sessions.py”, line 518, in request
resp = self.send(prep, **send_kwargs)
File “/usr/local/lib/python3.5/dist-packages/requests/sessions.py”, line 639, in send
r = adapter.send(request, **kwargs)
File “/usr/local/lib/python3.5/dist-packages/requests/adapters.py”, line 502, in send
raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPConnectionPool(host=‘192.168.1.3’, port=3480): Max retries exceeded with url: //data_request?id=sdata (Caused by NewConnectionError(’<requests.packages.urllib3.connection.HTTPConnection object at 0x7fb35d8c5e10>: Failed to establish a new connection: [Errno 111] Connection refused’,))
2017-09-12 01:58:45 ERROR (MainThread) [homeassistant.setup] Setup failed for vera: Component failed to initialize.

You’re getting a connection refused trying to talk from the HA installation to vera.

if you put in the following in a browser does it return a json response?
http://192.168.1.3:3480/data_request?id=sdata

i know it’s been a few months, but i’m going to try to get you a log at some point this weekend if i get a chance. it has gotten worse, not better…i turned the lights in my living room off at the switch about 10 minutes ago and HA still reports that they’re turned on. they just now turned off, according to HA. i’m wondering if it has something to do with only updating once i load the web interface, because they seem to have updated pretty quickly after i opened that up…

I’m having similar challenges… vera 3, ui v5.
lights and in particular several motion detectors end up in locked status until has restart.

I’ve noticed a couple of motion detectors locked on once or twice, but never had the chance to dig into what’s causing it, whether it be the z-wave device, vera, pyvera, or HA itself (it’s always when I’m away from home that I spot this). I’ll try and debug it next time it happens a bit more!

at least weekly event for me… my suspicion is output format, and dodgy vera.
I gave up troubleshooting, and hope to move alarm sensors onto HA directly and hope that a simplified vera config will eliminate the problem for the zwave lights.

I have a garage door sensor that reports correctly in Vera but somehow gets out of sync in HA. Shows open in HA, closed in Vera. It’s a Zigbee sensor but since Vera shows it correctly, HA should as well. Any suggestions???

did you try first taking a look at the vera sdata response, finding your garage door and confirming in there that it shows the right status. It should, as this is what is used on the vera ui.

In my case, the Vera has the correct data. I’m chalking it up to the instability of the Vera itself. Working on moving everything to HA where at least I know development is moving forward. Vera has stagnated…