Skip to content

fix(grafana): use IS TRUE for boolean comparisons in Copilot adoption… - #9133

Open
Thundercloud12 wants to merge 1 commit into
apache:mainfrom
Thundercloud12:fix/copilot_adoption_dashboard
Open

fix(grafana): use IS TRUE for boolean comparisons in Copilot adoption…#9133
Thundercloud12 wants to merge 1 commit into
apache:mainfrom
Thundercloud12:fix/copilot_adoption_dashboard

Conversation

@Thundercloud12

Copy link
Copy Markdown

⚠️ Pre-Checklist

Please complete ALL items in this checklist and remove this section before submitting.

  • I have read through the [Contributing Documentation](https://devlake.apache.org/community/).
  • I have added relevant tests (N/A for Grafana dashboard JSON; validated JSON syntax and query logic).
  • I have added relevant documentation.
  • I will add appropriate labels to the PR, such as pr-type/bug-fix, pr-type/feature-development, etc.

Summary

Fix Grafana panels in the GitHub Copilot Adoption dashboard that render "No data" on PostgreSQL deployments due to boolean/integer comparison type mismatches.

  • Replaced = 1 with the ANSI-standard IS TRUE for the used_agent and used_chat columns in:

    • Panel 12 (Agent Mode Adopters)
    • Panel 13 (Chat Adopters)
    • Panel 30 (Agent Users vs Chat Users Trend)
  • Updated both:

    • grafana/dashboards/postgresql/github-copilot-adoption.json
    • grafana/dashboards/mysql/github-copilot-adoption.json
  • Kept the PostgreSQL and MySQL dashboard definitions in sync to prevent regressions when the dashboards are updated or ported between database dialects.

Does this close any open issues?

Closes #9126

Screenshots

N/A — This is a query syntax alignment fix. The affected panels will display user counts instead of "No data".

Other Information

  • Both dashboard JSON files were validated for valid JSON formatting.
  • IS TRUE is supported natively by PostgreSQL for BOOLEAN values and by MySQL for boolean-like TINYINT(1) values.

@Thundercloud12

Copy link
Copy Markdown
Author

@stigi Hello! this is my first pr into this repository, picked up an issue which seemed simple, the issue was postgres evaluated it as true and false values and instead threw an error thats why used IS TRUE, works identically across both mysql and postgres
Thanks you!!

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.

[Bug][gh-copilot] PostgreSQL adoption dashboard compares boolean columns to integer, panels render "No data"

1 participant