Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I got this error after several successful executions #123

Open
masterchop opened this issue Feb 8, 2019 · 1 comment
Open

I got this error after several successful executions #123

masterchop opened this issue Feb 8, 2019 · 1 comment

Comments

@masterchop
Copy link

This is the error:

Traceback (most recent call last):
File "RoomLight_project.py", line 227, in
sys.exit(main() or 0)
File "RoomLight_project.py", line 189, in main
lapi.L_setLight("off", 5)
File "/home/pi/Scripts/Chop_Utils/LIFX_api.py", line 51, in L_setLight
bulb.set_power(state, duration)
File "/usr/local/lib/python3.5/dist-packages/lifxlan/light.py", line 56, in set_power
self.req_with_ack(LightSetPower, {"power_level": 0, "duration": duration})
File "/usr/local/lib/python3.5/dist-packages/lifxlan/device.py", line 477, in req_with_ack
self.req_with_resp(msg_type, Acknowledgement, payload, timeout_secs, max_attempts)
File "/usr/local/lib/python3.5/dist-packages/lifxlan/device.py", line 526, in req_with_resp
raise WorkflowException("WorkflowException: Did not receive {} from {} (Name: {}) in response to {}".format(str(response_type), str(self.mac_addr), str(self.label), str(msg_type)))
lifxlan.errors.WorkflowException: WorkflowException: Did not receive [<class 'lifxlan.msgtypes.Acknowledgement'>] from d0:73:d5:20:6d:c5 (Name: BedRoom Light) in response to <class 'lifxlan.msgtypes.LightSetPower'>

Any help is appreciated.

@samclane
Copy link
Contributor

For a quick-fix, putting rapid=True on your bulb.set_power call will bypass the req_with_ack, instead using a "fire-and-forget" policy.

How quickly are you calling lapi.L_setLight? Too much traffic can muck up your network's bandwidth and cause some ack packets to get lost/ignored.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants