Skip to content

Grafana dashboard consistency#173

Open
samuelLi05 wants to merge 2 commits into
mainfrom
grafana_dashboard_consistency
Open

Grafana dashboard consistency#173
samuelLi05 wants to merge 2 commits into
mainfrom
grafana_dashboard_consistency

Conversation

@samuelLi05
Copy link
Copy Markdown
Contributor

grafana ocd

Copilot AI review requested due to automatic review settings March 2, 2026 03:27
@samuelLi05 samuelLi05 requested a review from a team as a code owner March 2, 2026 03:27
@samuelLi05 samuelLi05 requested review from GrayM8 and celinayang13 and removed request for a team March 2, 2026 03:27
@gemini-code-assist
Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request primarily focuses on improving the consistency and readability of Grafana dashboard configurations by reformatting JSON files. Additionally, it refines the field override logic within these dashboards to ensure only relevant data series are displayed, enhancing the user experience. A minor update to a testing script's default car name is also included.

Highlights

  • Grafana Dashboard Formatting: JSON structures across multiple Grafana dashboard configuration files were reformatted for improved readability and consistency.
  • Enhanced Field Visibility Logic: The field override configurations in Grafana dashboards were updated to hide all fields by default using a regular expression, then explicitly display only the relevant fields for each panel.
  • Default Car Name Update: The paho_testing.py script's default car_name variable was changed from "Orion" to "Angelique".
Changelog
  • telemtry/analysis/database/dashboards/angelique/real-time/controls.json
    • Reformated JSON for improved readability.
    • Updated field overrides to hide all fields by default and explicitly show 'apps1_v', 'apps2_v', 'time', and 'packet_id'.
  • telemtry/analysis/database/dashboards/angelique/real-time/dynamics.json
    • Reformated JSON for improved readability.
    • Updated field overrides to hide all fields by default and explicitly show 'gps_heading', 'gps_velocity', 'flw_speed', 'frw_speed', 'blw_speed', 'brw_speed', 'time', and 'packet_id'.
  • telemtry/analysis/database/dashboards/angelique/real-time/electronics.json
    • Reformated JSON for improved readability.
    • Updated field overrides to hide all fields by default and explicitly show 'lv_power', 'gps_velocity', 'front_speed', 'rear_speed', 'time', and 'packet_id'.
  • telemtry/analysis/database/dashboards/angelique/real-time/low_voltage_battery.json
    • Reformated JSON for improved readability.
    • Updated field overrides to hide all fields by default and explicitly show 'lv_c', 'lv_v', 'time', and 'packet_id'.
  • telemtry/analysis/database/dashboards/angelique/real-time/thermals.json
    • Reformated JSON for improved readability.
    • Updated field overrides to hide all fields by default and explicitly show 'ambient_temp', 'motor_temp', 'inverter_temp', 'avg_cell_temp', 'max_cell_temp', 'min_cell_temp', 'flow_rate', 'time', and 'packet_id'.
  • telemtry/analysis/database/paho_testing.py
    • Changed the default car name from "Orion" to "Angelique".
Activity
  • No human activity (comments, reviews) has been recorded on this pull request yet.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request focuses on improving the consistency and maintainability of Grafana dashboards by refactoring the panel configurations. The changes simplify how data series are displayed, making the dashboards easier to manage. Additionally, a testing script has been updated. My feedback includes a suggestion to make this test script more flexible by using command-line arguments instead of a hardcoded value, which will improve its usability for developers.

if __name__ == '__main__':
logging.basicConfig(level=logging.INFO)
car_name = "Orion" # Change to "Nightwatch", "Angelique", or "Orion" as needed
car_name = "Angelique" # Change to "Nightwatch", "Angelique", or "Orion" as needed
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Hardcoding the car_name for testing purposes can be inconvenient for other developers who might need to test with a different car. This can lead to unnecessary code changes and potential merge conflicts.

Consider using command-line arguments to make the script more flexible. This would allow any developer to easily specify the car to test without modifying the source code.

For example, you could use Python's argparse module:

import argparse

if __name__ == '__main__':
    parser = argparse.ArgumentParser(description='Run paho testing for a specific car.')
    parser.add_argument('--car', type=str, default='Angelique', choices=['Nightwatch', 'Angelique', 'Orion'],
                        help='The name of the car to test.')
    args = parser.parse_args()

    logging.basicConfig(level=logging.INFO)
    car_name = args.car
    # ... rest of the script

Then you can run the script like this from your terminal: python paho_testing.py --car Orion.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR primarily reformats and standardizes the exported Grafana dashboard JSON for Angelique real-time dashboards to improve consistency and reduce noisy diffs, with one additional change in a local testing script.

Changes:

  • Reformat multiple Angelique real-time Grafana dashboard JSON files (pretty-printing / consistent structure).
  • Replace large per-field hide override lists with a simpler “hide everything by default” override plus explicit “unhide” overrides for the intended series.
  • Change the default car_name in paho_testing.py when executed as a script.

Reviewed changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
telemtry/analysis/database/paho_testing.py Changes the default car_name used for local/manual runs.
telemtry/analysis/database/dashboards/angelique/real-time/thermals.json Reformats dashboard JSON and simplifies field overrides (hide-all + explicit unhide).
telemtry/analysis/database/dashboards/angelique/real-time/low_voltage_battery.json Reformats dashboard JSON and simplifies field overrides.
telemtry/analysis/database/dashboards/angelique/real-time/electronics.json Reformats dashboard JSON and simplifies field overrides.
telemtry/analysis/database/dashboards/angelique/real-time/dynamics.json Reformats dashboard JSON and simplifies field overrides.
telemtry/analysis/database/dashboards/angelique/real-time/controls.json Reformats dashboard JSON and simplifies field overrides.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

if __name__ == '__main__':
logging.basicConfig(level=logging.INFO)
car_name = "Orion" # Change to "Nightwatch", "Angelique", or "Orion" as needed
car_name = "Angelique" # Change to "Nightwatch", "Angelique", or "Orion" as needed
Copy link

Copilot AI Mar 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is focused on Grafana dashboard formatting/consistency, but this change alters the default car_name used when running this script directly. That can unexpectedly change local test behavior for anyone relying on the previous default. Suggest reverting this default (or making it configurable via CLI arg/env var) and keeping dashboard-only changes in this PR.

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Member

@GrayM8 GrayM8 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants