Skip to content

starknet_transaction_prover: bump prover_panics_total on panic hook fire#14170

Open
avi-starkware wants to merge 1 commit into
avi/prover-v3/http-metricsfrom
avi/prover-v3/panic-counter
Open

starknet_transaction_prover: bump prover_panics_total on panic hook fire#14170
avi-starkware wants to merge 1 commit into
avi/prover-v3/http-metricsfrom
avi/prover-v3/panic-counter

Conversation

@avi-starkware
Copy link
Copy Markdown
Collaborator

Bumps the new prover_panics_total counter from the panic hook before
constructing the backtrace, so dashboards can alert on panic rate without
log search. The pre-registered zero observation in install_exporter
keeps the series visible at scrape time even before the first panic.

Co-Authored-By: Claude Opus 4.7 (1M context) noreply@anthropic.com

@cursor
Copy link
Copy Markdown

cursor Bot commented May 24, 2026

PR Summary

Low Risk
Observability-only change to the panic hook and metrics registration; no change to proving, RPC, or abort behavior.

Overview
Adds a prover_panics_total Prometheus counter so panic rate can be alerted on from metrics, not only structured logs.

The global panic hook now increments that counter first (before backtrace capture and error! logging), so a recursive panic in those steps still records the original event. install_exporter pre-registers the series at zero like other counters so /metrics exposes it before the first panic. A unit test asserts the hook bumps the counter by one when installed.

Reviewed by Cursor Bugbot for commit e503ebd. Bugbot is set up for automated code reviews on this repo. Configure here.

@reviewable-StarkWare
Copy link
Copy Markdown

This change is Reviewable

Bumps the new `prover_panics_total` counter from the panic hook before
constructing the backtrace, so dashboards can alert on panic rate without
log search. The pre-registered zero observation in `install_exporter`
keeps the series visible at scrape time even before the first panic.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@avi-starkware avi-starkware force-pushed the avi/prover-v3/panic-counter branch from cbd1def to e503ebd Compare May 24, 2026 16:48
@avi-starkware avi-starkware force-pushed the avi/prover-v3/http-metrics branch from 51ebd37 to 6c02d2b Compare May 24, 2026 16:48
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.

2 participants