-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
feat(usage overview): Introduce new table #104164
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
Conversation
❌ 1 Tests Failed:
View the top 3 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
static/gsApp/views/subscriptionPage/usageOverview/components/productTrialRibbon.tsx
Outdated
Show resolved
Hide resolved
| events: reserved ?? 0, // buckets use the converted unit reserved amount (ie. in GB for byte categories) | ||
| buckets: subscription.planDetails.planCategories[billedCategory], | ||
| }); | ||
| const recurringReservedSpend = isChildProduct ? 0 : (bucket.price ?? 0); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: getBucket may throw for add-on data categories
The getBucket function is called with planCategories[billedCategory] for all products including add-ons, but planCategories is typed as Partial<Record<DataCategory, EventBucket[]>> and may not contain entries for add-on data categories like seerAutofix or seerScanner. When the category doesn't exist, getBucket throws "Invalid data category for plan". This is inconsistent with how getBilledCategory in billing.tsx uses optional chaining when accessing planCategories, acknowledging entries may be missing. For add-ons, recurringReservedSpend would be set to 0 via isChildProduct ? 0 : ... anyway for child products, but parent add-on rows would still trigger the error.
Split out from #103983
Pt 6 of https://linear.app/getsentry/issue/BIL-1817/update-usage-overview-table-with-new-designs
Introduces the new table designs. Final PR will actually "GA" everything and remove the dead code.
