Skip to content

fix(web): usage hourly breakdown lists every hour chronologically - #7595

Merged
maria-rcks merged 1 commit into
pingdotgg:mainfrom
lgwacker:fix/usage-hourly-breakdown-order
Aug 19, 2026
Merged

fix(web): usage hourly breakdown lists every hour chronologically#7595
maria-rcks merged 1 commit into
pingdotgg:mainfrom
lgwacker:fix/usage-hourly-breakdown-order

Conversation

@lgwacker

@lgwacker lgwacker commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

Problem

On the Usage page, Past 24h + Breakdown Hour only lists hours with activity, newest first. With sparse activity the list jumps between distant hours (e.g. 1 PM6 PM) and reads as mis-ordered, even though the ordering itself is correct and the labels are in the system timezone.

Fix

Render every hour in the 24h window in the breakdown table — zero-filled, in chronological order — matching the chart above it, which already renders all 24 periods. Daily windows (up to 90 periods) keep the existing newest-first behavior.

breakdownPeriods now maps the window's hour enumeration to the merged hourly totals, falling back to a zero-filled row for inactive hours. The labels still use window.timeZone unchanged.

Closes #7594

Model: deepseek-v4-flash via opencode (OpenCode CLI)


Note

Low Risk
Display-only change on the Usage page breakdown table; no API, auth, or data pipeline changes.

Overview
Past 24h usage breakdown (Breakdown → Hour) no longer shows only hours that had activity, newest-first. It now walks the full window hour list in chronological order, using zero-filled rows for quiet hours so the table matches the hourly chart instead of jumping between sparse timestamps.

7/30/90 day breakdowns are unchanged: still newest-first via merged.daily.toReversed().

Adds a small zeroHour helper to build empty HourlyTotals rows when merging hourly data by hourStart.

Reviewed by Cursor Bugbot for commit 2119ffb. Bugbot is set up for automated code reviews on this repo. Configure here.

Note

Fix usage hourly breakdown to list all hours chronologically with zero-filled gaps

In UsagePage.tsx, the breakdownPeriods memo is reworked so that hourly windows build a Map keyed by hourStart and align entries to the full hours array, inserting zero-filled rows for hours with no activity. A new zeroHour helper constructs empty HourlyTotals objects for missing hours. Daily mode is unchanged and continues to display newest-first.

Macroscope summarized 2119ffb.

@coderabbitai

coderabbitai Bot commented Aug 19, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: c1eaa701-13f5-41cf-8f71-06cecd65323e

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

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

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added vouch:unvouched PR author is not yet trusted in the VOUCHED list. size:S 10-29 changed lines (additions + deletions). labels Aug 19, 2026
@macroscopeapp

macroscopeapp Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved at 2119ffb

Macroscope's review found this PR approvable — This is a minor UI display change that affects how hourly usage breakdowns are presented - showing all 24 hours chronologically with zero-filled entries instead of only hours with activity. The change is purely presentational with no backend or data logic impact.

You can add or adjust custom eligibility rules. Learn more.

@maria-rcks
maria-rcks merged commit 62654d2 into pingdotgg:main Aug 19, 2026
18 checks passed
github-actions Bot added a commit to omarcresp/t3code-flake that referenced this pull request Aug 20, 2026
## What's Changed
* fix(desktop): stop automatic passkey prompts by @t3dotgg in pingdotgg/t3code#7522
* fix(web): align version text with its label by @RakshithBhat03 in pingdotgg/t3code#7521
* fix(web): refresh open file with the file tree by @StiensWout in pingdotgg/t3code#7490
* Add OpenCode skill discovery by @dbalders in pingdotgg/t3code#3154
* feat(web): unify workspace navigation by @maria-rcks in pingdotgg/t3code#7153
* fix(web): hide opencode's plan agent when legacy plan mode is off by @UtkarshUsername in pingdotgg/t3code#6420
* feat: refine thread action menus by @maria-rcks in pingdotgg/t3code#7476
* feat(web): redesign usage insights by @maria-rcks in pingdotgg/t3code#7147
* fix(server): outdated gh no longer reads as "not authenticated" by @t3dotgg in pingdotgg/t3code#7588
* fix(desktop): refresh queued updates before install by @SunkenInTime in pingdotgg/t3code#6269
* feat(web): confirm before closing a terminal by @maria-rcks in pingdotgg/t3code#7592
* feat(web): refresh pull request details by @maria-rcks in pingdotgg/t3code#7148
* fix(web): usage hourly breakdown lists every hour chronologically by @lgwacker in pingdotgg/t3code#7595
* fix(web): remove the terminal pane's app-canvas gutter by @jakeleventhal in pingdotgg/t3code#6222
* feat(web): attach composer state drawers by @maria-rcks in pingdotgg/t3code#7150
* fix(server): preserve tool lifecycle identity by @maria-rcks in pingdotgg/t3code#7151
* chore(desktop): use stable Clerk Electron release by @t3dotgg in pingdotgg/t3code#7602


**Full Changelog**: pingdotgg/t3code@v0.0.34-nightly.20260819.1133...v0.0.34-nightly.20260820.1139

Upstream release: https://github.com/pingdotgg/t3code/releases/tag/v0.0.34-nightly.20260820.1139
sheehanmunim added a commit to munimtechnologies/mtcode that referenced this pull request Aug 20, 2026
Bring in T3 Code pingdotgg#7148 pingdotgg#7595 pingdotgg#6222 pingdotgg#7150 pingdotgg#7151 pingdotgg#7602 pingdotgg#7152 so the fork is not behind pingdotgg/t3code:main.

Co-authored-by: Cursor <cursoragent@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:S 10-29 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Usage Past 24h breakdown by hour omits inactive hours, making the hour list look mis-ordered

2 participants