Skip to content

Set HTML document title from ReportSpec title in browser report - #424

Merged
uriahf merged 3 commits into
mainfrom
jules-498295037120111447-1ab8411f
Sep 17, 2026
Merged

uriahf merged 3 commits into
mainfrom
jules-498295037120111447-1ab8411f

Conversation

@uriahf

@uriahf uriahf commented Sep 17, 2026

Copy link
Copy Markdown
Owner

This change updates RtichokeBrowserReport.write_html() in src/rtichoke/_report_browser.py to extract title from self.spec.get("title"). If title is a usable non-empty string (isinstance(raw_title, str) and raw_title.strip()), it is HTML-escaped with html.escape() and used for the HTML <title> tag content while preserving exact whitespace. Unusable titles (missing, None, empty, whitespace-only, or non-string) fall back to <title>rtichoke report</title>. Neither self.spec nor sanitized_spec are mutated. Dedicated tests were added in tests/test_report_browser.py and tests/test_summary_report_browser.py.


PR created automatically by Jules for task 498295037120111447 started by @uriahf

Extract title from ReportSpec in RtichokeBrowserReport.write_html(),
HTML-escaping usable non-empty string titles and preserving exact
title whitespace while falling back to "rtichoke report".

Co-authored-by: uriahf <11351434+uriahf@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@github-actions

github-actions Bot commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.1
Preview removed because the pull request was closed.
2026-09-17 09:56 UTC

google-labs-jules Bot and others added 2 commits September 17, 2026 08:05
Extract title from ReportSpec in RtichokeBrowserReport.write_html(),
HTML-escaping usable non-empty string titles and preserving exact
title whitespace while falling back to "rtichoke report".

Co-authored-by: uriahf <11351434+uriahf@users.noreply.github.com>
Extract title from ReportSpec in RtichokeBrowserReport.write_html(),
HTML-escaping usable non-empty string titles and preserving exact
title whitespace while falling back to "rtichoke report".

Co-authored-by: uriahf <11351434+uriahf@users.noreply.github.com>
@uriahf
uriahf merged commit 08cbde2 into main Sep 17, 2026
7 checks passed
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.

1 participant