refactor(weekly-rotation): rename Discover Weekly to Weekly Rotation - #14582
Merged
Conversation
Nothing here has ever reached a user -- the Optimizely ruleset is 100% `off`
and the feature is not even in the deployed web bundle -- so this renames the
whole surface rather than only the copy: components, files, hooks, query keys,
analytics event names, the SDK method, the feature flag key, and the web route
(/explore/discover-weekly -> /explore/weekly-rotation).
- `sdk.users.getDiscoverWeekly` -> `getWeeklyRotation`, calling the renamed
`/v1/users/{id}/weekly-rotation` endpoint. Not a breaking change: the method
was added after 16.0.0 was published, so it has never shipped under the old
name. Adds the changeset it was missing.
- The feature flag key becomes `weekly_rotation`. A flag key Optimizely does
not know falls through to the code default (false in production), so this is
safe to merge before the new flag exists.
Requires the matching api change (weekly-rotation endpoint) to be deployed
first.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
🦋 Changeset detectedLatest commit: de6bfc3 The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
2 tasks
dylanjeffers
added a commit
that referenced
this pull request
Sep 1, 2026
## Problem `Web Lint & Stylelint` fails on main at 02ee302, which takes the whole pipeline down with it — Web Build, Web Deploy, all three Desktop builds and the **Production Release Gate** every one skipped. Nothing from that run can ship. ``` 18:1 error `components/weekly-rotation` import should occur after import of `components/page/Page` import/order 27:1 error `components/weekly-rotation` import should occur after import of `components/tabs` import/order 25:1 error `components/weekly-rotation` import should occur after import of `components/nav/mobile/NavContext` import/order ✖ 4 problems (3 errors, 1 warning) ``` ## Cause #14582 renamed `components/discover-weekly` → `components/weekly-rotation` in place. `d` sorts before `header`/`lineup`/`nav`/`page`/`tabs`; `w` sorts after all of them, so the import line that was correctly placed under the old name is now out of order under the new one. Three call sites were affected. ## Fix Moved each `WeeklyRotationBanner` import to its new alphabetical position. Import-only change — no runtime difference, and `--fix` produces exactly this. - `pages/feed-page/components/desktop/FeedPageContent.tsx` - `pages/search-explore-page/components/desktop/SearchExplorePage.tsx` - `pages/search-explore-page/components/mobile/SearchExplorePage.tsx` ## Test plan - [x] All three files' `components/` import blocks verified in sorted order - [ ] CI lint green (the real check — this is the job that was failing) ## Note This is currently what blocks the production web deploy. The Production gate has five runs waiting back to Aug 24, including the 12/31/69 album-date fix (#14579); main HEAD couldn't join them because of this lint failure. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Renames the whole feature — copy, code, route, analytics, SDK method, and feature flag key.
Depends on AudiusProject/api#1031 (merged), which renames the endpoint to
/v1/users/{id}/weekly-rotation. That needs to be rolled out before this merges, or the client calls a 404.Why rename everything and not just the copy
Nothing here has ever reached a user. The Optimizely ruleset is 100% allocated to
off, and the production web bundle doesn't contain the feature at all — the web deploy runs for it are stillwaitingon the Production environment approval. This is the cheapest this rename will ever be, so it covers components, filenames, hooks, query keys, analytics event names, artwork assets, and the web route (/explore/discover-weekly→/explore/weekly-rotation).SDK
sdk.users.getDiscoverWeekly→getWeeklyRotation. Not a breaking change: the method was added on Aug 24, after 16.0.0 was published on Aug 3, so it has never existed in a released SDK. It was also missing a changeset, so this adds one.Feature flag
The key becomes
weekly_rotation. A new Optimizely flag needs to be created under that key; the olddiscover_weeklyflag is now orphaned. Safe to merge first —getFeatureEnabledcan't distinguish an unknown key from afalseone, so both fall through to the code default (falsein production).Verification
tsc --noEmitclean oncommon,web,mobile, andsdkresponsiveCoverage.test.tspassesNote for reviewers:
packages/commontypechecks against the built SDKdist, not source, so this needsnpm run build -w @audius/sdklocally beforecommonwill typecheck. web and mobile resolve to source and won't show the problem.🤖 Generated with Claude Code