-
-
Notifications
You must be signed in to change notification settings - Fork 13
Set platform order from generation scripts #502
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Summary of Changes
Hello @sven-oly, 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!
I've implemented a new feature that allows users to control the display order of platform columns in the test output summary dashboard. This provides flexibility beyond the default alphabetic sorting, enabling ordering by component count or a custom list of platforms. This change enhances the readability and customizability of the test reports, making it easier to analyze results based on specific platform priorities.
Highlights
- New Command-Line Option: I've introduced a new
--platform_ordercommand-line option toverifier.py, allowing users to specify how platform columns are arranged in the test output summary dashboard. - Flexible Ordering Options: This new option supports flexible ordering methods, including 'alphabetic' (default), 'component_count' (sorting by the number of test cases), or a custom, user-defined list of platform names.
- Default Configuration in Generation Scripts: The generation scripts (
genData100.shandgenerateDataAndRun.sh) have been updated to utilize this new option, setting a predefined default order for platforms. - Dynamic HTML Rendering: The
summary_template.htmlhas been enhanced with JavaScript to dynamically sort and display platform columns according to the specified order, ensuring that all platforms are shown, even if not explicitly listed in a custom order. - Backend Integration: Modifications were made in
testreport.pyandverifier.pyto properly handle and pass the newplatform_orderargument throughout the test reporting system.
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 in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.
| 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 issue 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 or fill out our survey to provide feedback.
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
-
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. ↩
There was a problem hiding this 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 introduces a new feature to control the order of platform columns in the test summary output. The changes are well-implemented across shell scripts, Python backend, and the HTML/JS frontend. My review focuses on improving code robustness, readability, and maintainability. I've suggested a few minor fixes, including correcting a typo in a help message, making the JavaScript code more robust for future platform names, and refactoring some Python code to improve clarity and reduce duplication.
verifier/summary_template.html
Outdated
| new Set(Array.from(exec_set)); | ||
| for (let platform of platform_order) { | ||
| // remove the underscores, too. | ||
| const pl2 = platform.replace('_', ' '); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The replace('_', ' ') call will only replace the first underscore in a platform name. If a platform name could ever contain multiple underscores (e.g., My_Awesome_Platform), this would lead to incorrect behavior. Using replaceAll() would be more robust for future changes.
const pl2 = platform.replaceAll('_', ' ');There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch.
echeran
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM

This adds a command line option to verifier.py to set the order of platform columns in the test output.
--platform_order Options include:
These are set to default values in the main generate scripts.
Note that if a platform with test cases is not mentioned in this list, it will be appended at the right of the dashboard.