diff --git a/bumblebee/modules/battery.py b/bumblebee/modules/battery.py index 57a12cc..5367d5f 100644 --- a/bumblebee/modules/battery.py +++ b/bumblebee/modules/battery.py @@ -105,8 +105,9 @@ class Module(bumblebee.engine.Module): state.append("AC") else: charge = "" - with open("{}/status".format(widget.name)) as f: - charge = f.read().strip() + try: + with open("{}/status".format(widget.name)) as f: + charge = f.read().strip() except IOError: pass if charge == "Discharging":