question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

cm-rgb-monitor stops running after sleep mode

See original GitHub issue

As said in the headline, after waking up my computer from suspend cm-rgb-monitor does not show anything anymore.

Steps to reproduce:

  • Start cm-rgb-monitor
  • suspend computer to ram
  • wake computer up again –> cm-rgb-monitor stops showing CPU load/temperature

Simple mitigation like a try/except in the eternal while loop don not work, neither does a while/True around the monitor() function.

if __name__ == '__main__':
    while True:
        try:
            monitor()
        except Exception as e:
            print(e)

Additional information:

  • cm-rgb 0.1.0
  • OS Kubuntu 20.04
  • Python 3.8

Error message:

Traceback (most recent call last):
  File "/home/---/Programs/cm-rgb/scripts/cm-rgb-monitor", line 162, in <module>
    monitor()
  File "/home/---/.local/lib/python3.8/site-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/home/---/.local/lib/python3.8/site-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/home/---/.local/lib/python3.8/site-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/---/.local/lib/python3.8/site-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/home/---/Programs/cm-rgb/scripts/cm-rgb-monitor", line 151, in monitor
    c.apply()
  File "/home/---/.local/lib/python3.8/site-packages/cm_rgb-0.1.0-py3.8.egg/cm_rgb/ctrl.py", line 83, in apply
    return self.send_packet(self.P_APPLY)
  File "/home/---/.local/lib/python3.8/site-packages/cm_rgb-0.1.0-py3.8.egg/cm_rgb/ctrl.py", line 80, in send_packet
    return self.device.read(64)
  File "hid.pyx", line 123, in hid.device.read
OSError: read error

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
mpsdskdcommented, May 14, 2020

Yes, that worked - but I had to remove the BindsTo and After lines and it is in /usr/local/bin for me.

I’d prefer if it was possible with the autostart folder and now cm-rgb-monitor runs as a system service (maybe I’ll try as a user systemd service later), but as long as my CPU lights up everything’s good^^

I still get the same error message in journalctl I posted above, but it automatically restarts.

1reaction
dominaliencommented, Feb 19, 2022

Yes, the service starts now and from limited testing continues working after resume from suspend.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Display issues after waking from sleep mode
My Dell E2414H monitor has display issues after waking from sleep mode. I am running Windows 10 with an Asus Z170 Pro4 motherboard...
Read more >
USB-C Monitor can't display after waking from sleep mode
The USB-C monitor does not display after the computer is waked up from sleep mode. When the computer resumes from sleep mode to...
Read more >
Computer does not wake from Sleep or Hibernate mode ...
Select [Other troubleshooters]③. Click [Run] on the Power option④, then follow the on-screen instructions to complete the troubleshooting ...
Read more >
If your Mac sleeps or wakes unexpectedly - Apple Support
Check your system's activity. Processes running in the background can prevent your Mac from sleeping. Check Activity Monitor to see if a process...
Read more >
Inkscape shuts down after monitor going into sleep mode
I'm running Inkscape on a Lenovo Yoga 530 touchscreen. ... However, I'm not sure if that's the same thing as sleep mode.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found