Skip to content

Commit

Permalink
fix: Handle missing ICP10125 sensor.
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewjw committed Jul 18, 2023
1 parent 543d9af commit c7a2ed2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion breakoutgardenexporter/icp10125.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def __init__(self) -> None:
def initialise(self, metrics: Metrics) -> bool:
try:
self.sensor = ICP10125()
except RuntimeError:
except (RuntimeError, OSError):
return False
else:
metrics.add_metric("bge_pressure", GAUGE, "The air pressure")
Expand Down

0 comments on commit c7a2ed2

Please sign in to comment.