Skip to content

ref(dashboards): Migrate mobileAppSize to React Query hooks#107062

Merged
DominikB2014 merged 3 commits intomasterfrom
dominikbuszowiecki/browse-260-migrate-mobileappsize-dataset-to-hook-pattern
Jan 27, 2026
Merged

ref(dashboards): Migrate mobileAppSize to React Query hooks#107062
DominikB2014 merged 3 commits intomasterfrom
dominikbuszowiecki/browse-260-migrate-mobileappsize-dataset-to-hook-pattern

Conversation

@DominikB2014
Copy link
Contributor

@DominikB2014 DominikB2014 commented Jan 27, 2026

Migrates the mobileAppSize dataset configuration from Promise-based API calls to React Query hook-based data fetching. The useSeriesQuery and useTableQuery will replace the old getSeriesRequest and getTableRequest in the config.

There's some duplication here between other dataset hooks, the plan is to extract shared functionality once all datasets are migrated.

Migrates the mobileAppSize dataset configuration from Promise-based
API calls to React Query hook-based data fetching.

Changes:
- Create useMobileAppSizeWidgetQuery.tsx with useSeriesQuery/useTableQuery hooks
- Update MobileAppSizeConfig to use new hooks instead of getSeriesRequest
- Add proper error extraction from API responses (responseJSON.detail)
- Support widget query queueing with async queue feature
- Add sampling mode support
- Remove obsolete getSeriesRequest test cases
- All 94 tests pass

The table query is a placeholder that returns empty data since
MobileAppSize only supports line chart visualizations.
@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Jan 27, 2026
@linear
Copy link

linear bot commented Jan 27, 2026

@DominikB2014
Copy link
Contributor Author

@cursor review

Copy link
Contributor

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

@DominikB2014 DominikB2014 requested a review from trevor-e January 27, 2026 16:32
@DominikB2014 DominikB2014 marked this pull request as ready for review January 27, 2026 16:32
@DominikB2014 DominikB2014 requested a review from a team as a code owner January 27, 2026 16:32
Copy link
Member

@trevor-e trevor-e left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested on my local data and seems to work alright! My main question is around the duplication going on across dataset fetching but I assume your team has a plan around that.

@DominikB2014 DominikB2014 merged commit 21ad092 into master Jan 27, 2026
55 checks passed
@DominikB2014 DominikB2014 deleted the dominikbuszowiecki/browse-260-migrate-mobileappsize-dataset-to-hook-pattern branch January 27, 2026 18:10
priscilawebdev pushed a commit that referenced this pull request Feb 2, 2026
Migrates the mobileAppSize dataset configuration from Promise-based API
calls to React Query hook-based data fetching. The `useSeriesQuery` and
`useTableQuery` will replace the old `getSeriesRequest` and
`getTableRequest` in the config.

There's some duplication here between other dataset hooks, the plan is
to extract shared functionality once all datasets are migrated.
@github-actions github-actions bot locked and limited conversation to collaborators Feb 12, 2026
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.

2 participants