-
Notifications
You must be signed in to change notification settings - Fork 161
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
Fix exp 881 #926
Open
Kartikayy007
wants to merge
9
commits into
google:main
Choose a base branch
from
Kartikayy007:fix-exp-881
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Fix exp 881 #926
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…dated section name (google#881) This PR enhances the report UI by adding syntax highlighting to both fuzz target code and build script code. and the Outdated section name Reference: GitHub PR google#867 Comment CC: @DonggeLiu Features Fuzz Target Code: Applies language-specific highlighting based on the benchmark YAML language field. Build Scripts: Uses Bash syntax highlighting for all build scripts, also added line numbers for build script code. Clean Display: Properly separates build script code from fixer prompts- Fixed Labeling: Corrects misleading "Fixer prompt" section that was previously showing build scripts. Implementation Details Added highlight.js library to base.html. Enhanced Benchmark class with a language field and extraction from YAML files. Updated Target class to separate build script code from fixer prompts. Modified templates to apply appropriate syntax highlighting and correct section labeling. added line numbers to build script code (used the same approach as for the fuzz target code) Bug Fixes Fixes issue where build scripts were incorrectly stored in the fixer_prompt field. Fixes misleading UI section headings by properly labelling build scripts as "Build Script".
…dated section name (google#881) This PR enhances the report UI by adding syntax highlighting to both fuzz target code and build script code. and the Outdated section name Reference: GitHub PR google#867 Comment CC: @DonggeLiu Features Fuzz Target Code: Applies language-specific highlighting based on the benchmark YAML language field. Build Scripts: Uses Bash syntax highlighting for all build scripts, also added line numbers for build script code. Clean Display: Properly separates build script code from fixer prompts- Fixed Labeling: Corrects misleading "Fixer prompt" section that was previously showing build scripts. Implementation Details Added highlight.js library to base.html. Enhanced Benchmark class with a language field and extraction from YAML files. Updated Target class to separate build script code from fixer prompts. Modified templates to apply appropriate syntax highlighting and correct section labeling. added line numbers to build script code (used the same approach as for the fuzz target code) Bug Fixes Fixes issue where build scripts were incorrectly stored in the fixer_prompt field. Fixes misleading UI section headings by properly labelling build scripts as "Build Script".
CC: @DonggeLiu |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix Sample Page Rendering Issues
Problem
mentioned in #883

Sample pages were failing to render with these errors:
The template was using a filter called
splitlines
which wasn't registered in the Jinja2 environment. Additionally, the template also lacking robustness against undefined variables.Files Changed for #883
report/web.py
- Added missing filter and improved error handlingreport/templates/sample.html
- Added robustness checksChanges Made
Added missing filter:
_splitlines
method inweb.py
Improved template robustness:
is defined
checks for variables that might be missing|default()
filterremove_trailing_empty_lines
filter handle edge cases betterEnhanced error handling:
These improvements should resolve all the sample page rendering issues.