Skip to content

Grafana exporter's no-source-tables guard doesn't recognize review_audit #3554

Description

@JSONbored

Summary

Follow-up to #3511/#3535, flagged as a non-blocking nit on #3535's own review.

scripts/export-grafana-reporting-db.sh's "does this database have any reporting signal at all" fail-safe guard (both the Postgres and SQLite variants) only checks for pull_requests/advisories/review_targets/ai_usage_events. Since #3535, the still-open-PR verdict computation also depends on review_audit, but the guard's table list was never updated to reflect that.

Not a live bug in practice — pull_requests already dominates the OR-condition on any real deployment, so the guard has never actually misfired. But a database containing only review_audit (no other listed table) would be misclassified as "no reporting signal" and trigger the "preserve the last-good snapshot" fail-safe incorrectly.

Fix

Add review_audit to both variants of the guard's table list.

Metadata

Metadata

Assignees

No one assigned

    Labels

    gittensor:bugGittensor-scored bug fix — scores a 0.05x multiplier.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions