-
Notifications
You must be signed in to change notification settings - Fork 621
Fix RPC usage page to handle missing peak date #6748
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix RPC usage page to handle missing peak date #6748
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #6748 +/- ##
=======================================
Coverage 54.80% 54.80%
=======================================
Files 895 895
Lines 56384 56384
Branches 3848 3848
=======================================
Hits 30899 30899
Misses 25390 25390
Partials 95 95
🚀 New features to boost your workflow:
|
size-limit report 📦
|
Merge activity
|
This PR adds a null check for the peak date in the RPC Usage page to handle cases where there are no requests in the last 24 hours. It displays "No Requests in last 24 hours" instead of attempting to format a non-existent date. Additionally, it destructures the `averageRate` directly from the API data to improve code readability when passing it to the RateGraph and CountGraph components.
03d6d4e to
0aca563
Compare

This PR adds a null check for the peak date in the RPC Usage page to handle cases where there are no requests in the last 24 hours. It displays "No Requests in last 24 hours" instead of attempting to format a non-existent date. Additionally, it destructures the
averageRatedirectly from the API data to improve code readability when passing it to the RateGraph and CountGraph components.PR-Codex overview
This PR enhances the
RPCUsagecomponent by incorporatingaverageRatefromapiData.data. It modifies the display logic forpeakRate.dateand updates data references in theRateGraphandCountGraphcomponents to utilize the newaverageRatevariable.Detailed summary
averageRateto destructuredapiData.data.peakRate.dateto handle cases with no requests.dataprop inRateGraphfromapiData.data.averageRatetoaverageRate.dataprop inCountGraphfromapiData.data.averageRatetoaverageRate.