Skip to content

Conversation

@mpkossen
Copy link
Contributor

Always write value for apt_upgrades_pending and apt_upgrades_held to ensure monitoring works.

If there are no held packages or no pending upgrades, nothing is written to apt.prom, resulting in monitoring dashboards not picking up on these values. This patch fixes that by ensuring there's always a value for apt_upgrades_pending and apt_upgrades_held .

@mpkossen mpkossen force-pushed the master branch 2 times, most recently from c68a096 to 03591a4 Compare April 14, 2025 23:52
@varac
Copy link

varac commented Aug 30, 2025

@mpkossen Thanks for this PR, I stumbled across this because my apt_upgrades_pending value doesn't return to 0 anymore after upgrading to Debian Trixie, which ships a newer version of this script than Debian Bookworm.

@prometheus-community: Please merge this soon, it's a regression from a monitoring standpoint. Thanks !

@varac
Copy link

varac commented Aug 30, 2025

@mpkossen Can you please fix the GH actions Lint/flake8 error ? Unfortunatly the log is expired, so pushing again might trigger a new one.

…ensure monitoring works.

Signed-off-by: Maarten Kossen (mpkossen) <[email protected]>
Signed-off-by: Maarten Kossen (mpkossen) <[email protected]>
Signed-off-by: Maarten Kossen (mpkossen) <[email protected]>
Signed-off-by: Maarten Kossen (mpkossen) <[email protected]>
Signed-off-by: Maarten Kossen (mpkossen) <[email protected]>
@dswarbrick dswarbrick merged commit b323e37 into prometheus-community:master Aug 30, 2025
4 checks passed
@varac
Copy link

varac commented Aug 30, 2025

@dswarbrick Awesome, thanks for the quick response !

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

Successfully merging this pull request may close these issues.

3 participants