Skip to content

Conversation

@dashed
Copy link
Member

@dashed dashed commented Dec 10, 2025

Closes https://linear.app/getsentry/issue/BIL-1813/stack-3-migrate-format-functions-to-use-formatting-config

Continues from #104025

  • Update formatReservedWithUnits to use formatting.unitType instead of isByteCategory() check
  • Update formatUsageWithUnits to use formatting.unitType instead of isByteCategory() and isContinuousProfiling() checks
  • Update convertUsageToReservedUnit to use formatting.unitType
  • Remove unused imports of isByteCategory and isContinuousProfiling

@dashed dashed requested a review from a team December 10, 2025 18:18
@dashed dashed self-assigned this Dec 10, 2025
@linear
Copy link

linear bot commented Dec 10, 2025

@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Dec 10, 2025
@dashed dashed force-pushed the BIL-952/format-functions-3 branch from 0d531c8 to 923605e Compare December 10, 2025 18:45
Base automatically changed from BIL-952/chart-functions-2 to master December 10, 2025 19:48
@dashed dashed force-pushed the BIL-952/format-functions-3 branch from 923605e to 6f51ba9 Compare December 10, 2025 19:51
Comment on lines +156 to +159
const categoryInfo = getCategoryInfoFromPlural(dataCategory);
const unitType = categoryInfo?.formatting.unitType ?? 'count';

if (unitType !== 'bytes') {

This comment was marked as outdated.

… formatting

- Update formatReservedWithUnits to use formatting.unitType instead of
  isByteCategory() check
- Update formatUsageWithUnits to use formatting.unitType instead of
  isByteCategory() and isContinuousProfiling() checks
- Update convertUsageToReservedUnit to use formatting.unitType
- Remove unused imports of isByteCategory and isContinuousProfiling

Part of BIL-952: Move formatting functions to DATA_CATEGORY_INFO
@dashed dashed merged commit 45f0d9a into master Dec 12, 2025
48 checks passed
@dashed dashed deleted the BIL-952/format-functions-3 branch December 12, 2025 00:42
@github-actions github-actions bot locked and limited conversation to collaborators Dec 27, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants