Skip to content

fix: stop replacing the shell's query client site-wide - #635

Merged
arbrandes merged 1 commit into
openedx:masterfrom
arbrandes:arbrandes/634-drop-query-client-provider
Sep 28, 2026
Merged

arbrandes merged 1 commit into
openedx:masterfrom
arbrandes:arbrandes/634-drop-query-client-provider

Conversation

@arbrandes

Copy link
Copy Markdown
Contributor

Description

src/providers.tsx handed frontend-base a QueryClientProvider, but app providers wrap the entire site rather than just the app's own routes, so any site installing gradebookApp ran every other app's data fetching through gradebook's client and its settings. That only started to matter now that #632 lets gradebook share a site with the instructor dashboard.

The provider is gone and gradebook's query options (5-minute staleTime, no refetch on focus, no retry on 4xx) now live in src/data/queryOptions.ts, spread into the app's own query hooks. Query keys are already namespaced under ['gradebook'], so sharing the shell's cache doesn't collide.

Fixes #634

LLM usage notice

Built with assistance from Claude.

@codecov

codecov Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.60%. Comparing base (92d6b7d) to head (82a58f1).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #635      +/-   ##
==========================================
- Coverage   98.60%   98.60%   -0.01%     
==========================================
  Files         113      112       -1     
  Lines        1221     1220       -1     
  Branches      209      205       -4     
==========================================
- Hits         1204     1203       -1     
- Misses         16       17       +1     
+ Partials        1        0       -1     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@arbrandes
arbrandes force-pushed the arbrandes/634-drop-query-client-provider branch 2 times, most recently from abe6408 to 9afd3ad Compare September 28, 2026 17:52
App providers wrap the whole site, so gradebook's QueryClientProvider
imposed its settings on every other app sharing the site. Its query
options now live on gradebook's own hooks.

Fixes openedx#634

Co-Authored-By: Claude <noreply@anthropic.com>
@arbrandes
arbrandes force-pushed the arbrandes/634-drop-query-client-provider branch from 9afd3ad to 82a58f1 Compare September 28, 2026 18:01
@arbrandes
arbrandes merged commit 93f7544 into openedx:master Sep 28, 2026
6 checks passed
@arbrandes
arbrandes deleted the arbrandes/634-drop-query-client-provider branch September 28, 2026 20:52
@openedx-semantic-release-bot

Copy link
Copy Markdown

🎉 This PR is included in version 2.0.0-alpha.6 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Gradebook replaces the shell's query client for the whole site

3 participants