You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(web,mobile): workflow step times use the app language's decimal separator - #48924
Workflow step times under 10 seconds ignore the app language's decimal separator. workflowStepTime builds them with toFixed(1), so with the app in German a step reads 1.5 s instead of 1,5 s.
Repro on upstream main (e95e4a9a0c): set Settings → General → Language to Deutsch, run a workflow with a step that takes about 1.5 seconds, and open the run. The step's time in the timeline reads 1.5 s.
Change
workflowStepTime now takes the app's formatting locale and formats the sub-10 s value with a cached Intl.NumberFormat(locale, { minimumFractionDigits: 1, maximumFractionDigits: 1 }), the same approach as formatAttachmentSize in #48167. It still rounds with toFixed(1) first, so English output stays byte-identical (Intl alone would round 1.45 s up to 1.5, where the column reads 1.4). The locale argument is required, so every caller has to pass one. The web run feed (WorkflowRunFeed.tsx) and the mobile timeline (WorkflowTimeline.tsx) pass useFormattingLocale() at their three call sites each.
No contracts, providers, server code or connection modes change.
Scope
This is a small fix for an obvious bug, so under CONTRIBUTING.md it needs no issue. It follows the app-language decimal fixes already merged: #48167 (ZIP sizes), #48321 (byte sizes) and #48605 (terminal font sizes). No open PR changes this function or its call sites.
Out of scope: the shared formatDuration (packages/shared/src/orchestrationTimingCopy.ts) has the same dot for 1–10 s values, including the run header's dauerte 1.5 s visible in the captures below. It is used in 14 files and #29495 is open on that file, so it is left for a separate change.
Verification
Unit: packages/client-runtime/src/workflows.test.ts gets a German case (1_500 ms → 1,5s in de), which fails on base (1.5s) and passes with the fix. The existing English cases now pass en-US, plus one guard that 1,450 ms still reads 1.4s.
Scenario scripts/scenarios/workflow-step-time-follows-app-language.e2e.ts, run with vp run scenarios:prove --base e95e4a9a0c. It switches the app to Deutsch, starts a one-step workflow whose step sleeps 1.5 s, opens the run, waits for a finished decimal time on the step row, then asserts a comma.
vp run check:changed upstream/main passes format, lint, knip, typecheck (7 packages), the React Compiler check (2 files) and tests.
Proven: the scenario fails on base e95e4a9a0c and passes on head b5cf4b4282.
Base e95e4a9a0c
Head b5cf4b4282
Result
❌ failed ASSERTION_FAILED: expected /\d,\d\s?s$/, observed Wait a bit 1.5 s
✅ passed
Workflow run in German
Not checked: mobile was not run in a client. It shares workflowStepTime and the unit test, and its typecheck passes.
…eparator
Sub-10 s step times were built with toFixed, so German showed "1.5 s". Format them with the app's formatting locale, as attachment sizes already do.
Macroscope's review found this PR approvable — Workflow duration labels on web and mobile now use the app language’s decimal separator while preserving existing rounding. The change is limited to presentation and does not alter workflow execution or product defaults.
You can add or adjust custom eligibility rules. Learn more.
Reviewing files that changed from the base of the PR and between b5cf4b4 and 01f79d1.
You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.
Use the checkbox below for a quick retry:
Trigger review
No actionable comments were generated in the recent review.
Walkthrough
Workflow step durations now use the selected formatting locale for fractional seconds in mobile and web timelines. Unit and end-to-end tests cover decimal formatting, including German comma separators.
workflowStepTime now accepts a locale and uses cached Intl.NumberFormat instances for fractional-second durations. Tests cover 1,450 ms formatting and German decimal separators.
Pass locale through workflow timelines apps/mobile/src/features/workflows/WorkflowTimeline.tsx, apps/web/src/components/workflows/WorkflowRunFeed.tsx
Mobile and web timelines read the formatting locale and pass it to duration formatting for completed steps, quick rows, and parallel groups.
Workflow step durations under ten seconds now use the app's formatting locale for the decimal separator, so German shows 1,5s. English output is unchanged. No merge-blocking risk was found.
Pre-merge checks: 4
Check name
Status
Explanation
Title check
The title names the main change: workflow step times now use the app language's decimal separator. It matches the web and mobile changes in the summary and the stated objective. The title uses the con…
Description check
The description follows the template sections: Problem, Change, Scope, and Verification. The Problem section gives the bug, the reproduction steps, and the observed output. The Change section explains…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title names the main change: workflow step times now use the app language's decimal separator. It matches the web and mobile changes in the summary and the stated objective. The title uses the conventional commit form. It names the web and mobile scopes, which the changeset covers.
Full details: Description check
Explanation
The description follows the template sections: Problem, Change, Scope, and Verification. The Problem section gives the bug, the reproduction steps, and the observed output. The Change section explains the locale handling and the call sites. The Scope section explains why no issue is linked and lists related PRs. The Verification section gives unit and scenario results, includes before and after evidence, and states what was not checked (mobile was not run in a client). The template asks for an agent attribution line at the end, and the description includes one ("Claude Opus 5.5 via T3 Code"). The description is complete and the only open point is the unverified mobile client run, which the author states openly.
Finishing Touches
Generate unit tests (beta)
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
Real web client, Chromium, 1280×800, light theme, app language Deutsch; fresh synthetic state on both commits.
On each commit, start the real web app on a fresh scenario database (T3CODE_DEV_SEED=0), create one synthetic project, enable Workflows through server.updateSettings, select Deutsch in Settings → General and wait for Sprache, write slow-step.ts with a real T3.step named Wait a bit that sleeps 1500 ms, run workflow start slow-step --key one --json, and open the completed run. Capture its timeline and check the step reads 1,5 s.
Scenario: Completed workflow step uses the German decimal separator
❌ failed ASSERTION_FAILED: expect.toHaveText failed locator: getByRole("button", name: /^Wait a bit/) expected: text /Wait a bit\s1,5\ss/ observed: text "Wait a bit 1.5 s" (match count 1)
This file contains hidden or 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
size:L100-499 changed lines (additions + deletions).vouch:unvouchedAuthor is not yet trusted in the VOUCHED list.
2 participants
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.
Problem
Workflow step times under 10 seconds ignore the app language's decimal separator.
workflowStepTimebuilds them withtoFixed(1), so with the app in German a step reads1.5 sinstead of1,5 s.Repro on upstream
main(e95e4a9a0c): set Settings → General → Language to Deutsch, run a workflow with a step that takes about 1.5 seconds, and open the run. The step's time in the timeline reads1.5 s.Change
workflowStepTimenow takes the app's formatting locale and formats the sub-10 s value with a cachedIntl.NumberFormat(locale, { minimumFractionDigits: 1, maximumFractionDigits: 1 }), the same approach asformatAttachmentSizein #48167. It still rounds withtoFixed(1)first, so English output stays byte-identical (Intlalone would round 1.45 s up to1.5, where the column reads1.4). Thelocaleargument is required, so every caller has to pass one. The web run feed (WorkflowRunFeed.tsx) and the mobile timeline (WorkflowTimeline.tsx) passuseFormattingLocale()at their three call sites each.No contracts, providers, server code or connection modes change.
Scope
This is a small fix for an obvious bug, so under CONTRIBUTING.md it needs no issue. It follows the app-language decimal fixes already merged: #48167 (ZIP sizes), #48321 (byte sizes) and #48605 (terminal font sizes). No open PR changes this function or its call sites.
Out of scope: the shared
formatDuration(packages/shared/src/orchestrationTimingCopy.ts) has the same dot for 1–10 s values, including the run header'sdauerte 1.5 svisible in the captures below. It is used in 14 files and #29495 is open on that file, so it is left for a separate change.Verification
packages/client-runtime/src/workflows.test.tsgets a German case (1_500ms →1,5sinde), which fails on base (1.5s) and passes with the fix. The existing English cases now passen-US, plus one guard that 1,450 ms still reads1.4s.scripts/scenarios/workflow-step-time-follows-app-language.e2e.ts, run withvp run scenarios:prove --base e95e4a9a0c. It switches the app to Deutsch, starts a one-step workflow whose step sleeps 1.5 s, opens the run, waits for a finished decimal time on the step row, then asserts a comma.vp run check:changed upstream/mainpasses format, lint, knip, typecheck (7 packages), the React Compiler check (2 files) and tests.Proven: the scenario fails on base
e95e4a9a0cand passes on headb5cf4b4282.e95e4a9a0cb5cf4b4282ASSERTION_FAILED: expected/\d,\d\s?s$/, observedWait a bit 1.5 sNot checked: mobile was not run in a client. It shares
workflowStepTimeand the unit test, and its typecheck passes.Claude Opus 5.5 via T3 Code