Skip to content

fix(chat): load HTML reports when the filename limit splits an emoji - #42478

Open
jadelike-wine wants to merge 3 commits into
pingdotgg:mainfrom
jadelike-wine:codex/fix-html-report-filename
Open

jadelike-wine wants to merge 3 commits into
pingdotgg:mainfrom
jadelike-wine:codex/fix-html-report-filename

Conversation

@jadelike-wine

Copy link
Copy Markdown
Contributor

Problem

Publish an inline HTML report with html_render using a title of 119 ASCII letters followed by 🚀. Chat shows “Unable to load”. The 120-unit filename limit cuts the emoji in half, and the server throws URIError when it encodes that filename in the attachment URL.

Change

Drop a trailing lone surrogate after truncating the filename stem. A whole emoji that fits stays in the name. The report keeps its original title.

Scope

This is a small, reproducible bug in the shared HTML filename helper used by Web and mobile, so there is no separate issue. Only that helper and its regression test change.

Verification

  • vp test run packages/shared/src/htmlRender.test.ts: the 119-letter case failed on main and passes with the fix. The 118-letter case preserves the complete rocket before .html. All 26 tests pass.
  • A local test agent called the real thread-scoped html_render tool. On main the Web client showed “Unable to load” and the server logged URIError: URI malformed. With the fix, the same report rendered in chat. I checked its heading both inline and in full screen. Native mobile was not run.
  • vp run check:changed upstream/main passed, including typechecking 37 packages and running 28 tests.
Before After
Chat shows Unable to load in place of the report. The same chat displays the November release checks report.

Model: GPT-6. Harness: Codex Desktop.

@github-actions github-actions Bot added vouch:unvouched Author is not yet trusted in the VOUCHED list. size:XS 0-9 changed lines (additions + deletions). labels Nov 24, 2026
@coderabbitai

coderabbitai Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

htmlRenderFileName removes a trailing unmatched high surrogate after truncation. A boundary test checks whether a rocket emoji is retained at the 120-character limit.

Changes: HTML filename truncation

Layer / File(s) Summary
Truncate filenames and verify emoji boundary
packages/shared/src/htmlRender.ts, packages/shared/src/htmlRender.test.ts
htmlRenderFileName removes a trailing unmatched high surrogate after truncation. The test checks that 118 preceding characters retain the rocket emoji, while 119 do not.

Estimated code review effort: 2 (Simple) | ~5 minutes

Change: Bug fix · Severity of issue fixed: Low

Suggested reviewers: juliusmarminge

Merge Risk: Minimal · up to bb870

This fixes HTML reports failing to load when the filename limit splits an emoji. The change is small and covered by a regression test, with no remaining merge-blocking risk identified.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: the HTML report filename helper now drops a split emoji after truncation, so chat loads the report. It is a conventional commit with a plain-language summary that matc…
Description check Passed The description follows the template. It has Problem, Change, Scope, and Verification sections. The problem, the one-line fix, and the reason no issue is linked are all stated. Verification lists focu…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the main change: the HTML report filename helper now drops a split emoji after truncation, so chat loads the report. It is a conventional commit with a plain-language summary that matches the raw summary and the objectives.

Full details: Description check

Explanation

The description follows the template. It has Problem, Change, Scope, and Verification sections. The problem, the one-line fix, and the reason no issue is linked are all stated. Verification lists focused test results, a manual check, and before/after screenshots. It also names the model and harness. It does not state that native mobile was tested, but it says so explicitly, which meets the template's request to state what was not checked.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 504abd4 and bb8701e.

Files selected for processing: 1

  • packages/shared/src/htmlRender.test.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.

@juliusmarminge juliusmarminge added the takeover:in-progress A takeover lead is working on this PR label Nov 24, 2026

This branch has not been deployed

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

Labels

size:XS 0-9 changed lines (additions + deletions). takeover:in-progress A takeover lead is working on this PR vouch:unvouched Author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants