Skip to content

test(i18n): check display-only error messages in one source scan - #9667

Open
PresentJay wants to merge 1 commit into
ParadevAI:mainfrom
PresentJay:test/i18n-single-scan
Open

PresentJay wants to merge 1 commit into
ParadevAI:mainfrom
PresentJay:test/i18n-single-scan

Conversation

@PresentJay

@PresentJay PresentJay commented Nov 12, 2026 •

Copy link
Copy Markdown

What & why

The translation audit read every source file twice, once for direct uses and once for aliases. Run both checks on the same contents. This preserves the file filters, patterns and line diagnostics while avoiding the second traversal that contributed to a macOS timeout.

How I tested it

  • On this branch, macOS arm64 with Bun 1.4.3 and TERM=dumb: from packages/i18n, bun test test/display-only.test.ts — 10 pass, 0 fail.
  • This patch was also part of the combined macOS verification for fix(desktop): let IME users confirm text without submitting a chat answer #9625: all 30 repository test tasks passed in one uncached run, with default workers and timeouts. Repo-wide lint and typecheck passed on that combined checkout.

Checklist

  • Conventional PR title
  • Lint and typecheck passed on the combined verification checkout
  • Allow maintainer edits
  • Signed CLA

Summary by cubic

Combines the direct-use and alias checks in the i18n display-only test into a single file scan, removing the second traversal that contributed to a macOS timeout while preserving file filters and line diagnostics.

Written for commit d84fd9b. Summary will update on new commits.

View guided diff

Summary by CodeRabbit

  • Tests
    • Simplified an existing check for matching strings assigned from error messages.

@coderabbitai

coderabbitai Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The display-only test now checks aliases for values assigned from errorMessage() during the existing source-file scan. It removes the separate glob scan and its repeated file and source checks.

Changes: i18n display-only test scan

Layer / File(s) Summary
Alias check in existing scan
packages/i18n/test/display-only.test.ts
The alias check reuses source text from the existing scan. A comment documents the check, and the separate scan and repeated checks are removed.

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Other

Suggested reviewers: kitenite

Merge Risk: Minimal · up to d84fd

This is a test-only change that makes the i18n display-only audit scan source files once instead of twice. It does not affect production behavior, and no merge-blocking risk is evident.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title describes the main change: the translation audit's display-only error message check now runs within one source-file scan instead of a separate second glob scan. It uses conventional commit f…
Description check Passed The description covers the What & why section, explaining that the audit previously read each source file twice and now runs both checks on the same contents to avoid a second traversal linked to a ma…
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 describes the main change: the translation audit's display-only error message check now runs within one source-file scan instead of a separate second glob scan. It uses conventional commit format (type(scope): subject) and matches the raw summary and objectives. Length is 64 characters, which is acceptable.

Full details: Description check

Explanation

The description covers the What & why section, explaining that the audit previously read each source file twice and now runs both checks on the same contents to avoid a second traversal linked to a macOS timeout. The How I tested it section gives concrete commands, platform, and results. The checklist is filled in. The template asks for an issue link, which is not given, but the PR is linked to #9625 for verification. Screenshots are not needed since the change is not user-visible. The description is mostly complete.

Finishing Touches

Generate unit tests (beta)

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

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 0bcdbe05-d74b-4f0d-8d5f-3e92c32eaa67
Commits

Reviewing files that changed from the base of the PR and between e9dc091 and d84fd9b.

Files selected for processing: 1

  • packages/i18n/test/display-only.test.ts

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

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

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant