vanviegen / hue-thief

Factory reset Philips Hue bulbs using an EZSP-based Zigbee USB stick. After a reset, bulbs can easily join any type of compatible bridge.
GNU General Public License v3.0
178 stars 20 forks source link

Continuous Loop of exceptions on start #13

Closed ndrwstn closed 3 years ago

ndrwstn commented 4 years ago

Installing per README.md, I end up in a loo (below) that I need to interrupt.

I've tried it on both Ubuntu 18.04 and on a Pi running Raspbian Desktop 2020-05-27, as well as within docker. I'm trying to use a Nortek HZUSB-1 if that matters.

Scanning on channel 11
Exception running handler
Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.7/site-packages/bellows/ezsp.py", line 194, in handle_callback
    handler(*args)
  File "hue-thief.py", line 54, in cb
    resp = interpanZll.ScanResp.deserialize(data)[0]
  File "/home/pi/2020-06-19_HueThief/interpanZll.py", line 40, in deserialize
    v, data = field[1].deserialize(data)
  File "/home/pi/.local/lib/python3.7/site-packages/zigpy/types/basic.py", line 287, in deserialize
    item, data = r._itemtype.deserialize(data)
  File "/home/pi/.local/lib/python3.7/site-packages/zigpy/types/basic.py", line 17, in deserialize
    raise ValueError("Data is too short to contain %d bytes" % cls._size)
ValueError: Data is too short to contain 1 bytes
Exception running handler
Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.7/site-packages/bellows/ezsp.py", line 194, in handle_callback
    handler(*args)
  File "hue-thief.py", line 54, in cb
    resp = interpanZll.ScanResp.deserialize(data)[0]
  File "/home/pi/2020-06-19_HueThief/interpanZll.py", line 40, in deserialize
    v, data = field[1].deserialize(data)
  File "/home/pi/.local/lib/python3.7/site-packages/zigpy/types/basic.py", line 287, in deserialize
    item, data = r._itemtype.deserialize(data)
  File "/home/pi/.local/lib/python3.7/site-packages/zigpy/types/basic.py", line 17, in deserialize
    raise ValueError("Data is too short to contain %d bytes" % cls._size)
ValueError: Data is too short to contain 1 bytes

Thanks for any help and I'll be happy to run any commands or troubleshoot further if you think it's on my end?

Finally, sorry about the weird double-tap; I don't know how I created an issue accidentally.

Claw256 commented 3 years ago

I am also having the same error.

Claw256 commented 3 years ago

Solved, I managed to solve the error by unplugging the USB and plugging it back in.

ndrwstn commented 3 years ago

Plugging and unplugging while running or before you started the script?

Claw256 commented 3 years ago

@ndrwstn Yes, I unplugged the ZigBee USB, then I restated the script and it worked for me.

vautieri commented 3 years ago

I did the docker install and get this same issue. I unplugged/reinserted to try again with no luck. I wonder if it is because I have some other zigbee devices around, as well as my hot water/Rinnai which I know uses zigbee (custom not real zigbee in what they told me when I wanted to automate it)

vanviegen commented 3 years ago

This is probably caused by some device giving interesting responses. I didn't investigate any further, but silenced the warnings.