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

BootCount not updated when posting to AirGradient is disabled #253

Open
dtrejod opened this issue Oct 6, 2024 · 1 comment
Open

BootCount not updated when posting to AirGradient is disabled #253

dtrejod opened this issue Oct 6, 2024 · 1 comment

Comments

@dtrejod
Copy link

dtrejod commented Oct 6, 2024

Problem

When using the local server API to get air gradient sensor data, I noticed the boot and bootCount values were not being updated. This only happened after I configured postDataToAirGradient: false. I have a simple airgradient prometheus exporter that I used to gather the local server metrics into a Prometheus instance. You can see from the below Grafana graph before postDataToAirGradient: false, the boot count metric was incremented every 1m. After the change, the bootCount value doesn't increment.

Screenshot 2024-10-06 at 11 47 16

Analysis

It appears bootCount is incremented in the sendDataToServer() func. The func returns early, not incrementing bootCount, when posting to airgradient servers is disabled.

@airgradienthq
Copy link
Owner

Yes good point. We will fix in one of the next updates.

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