fix(feed): back For You feed with live /tracks/recommended endpoint#14448
Closed
dylanjeffers wants to merge 1 commit into
Closed
fix(feed): back For You feed with live /tracks/recommended endpoint#14448dylanjeffers wants to merge 1 commit into
dylanjeffers wants to merge 1 commit into
Conversation
The dedicated GET /v1/users/{id}/feed/for-you endpoint is not yet rolled
out across the validator-node fleet and 404s in production, so the For
You tab renders empty. Fall back to GET /v1/tracks/recommended
(sdk.tracks.getRecommendedTracks) — the same personalized recommendation
source the Explore page used before the For You feed existed, which
reliably returns 200 from api.audius.co today.
/tracks/recommended has no offset param, so pagination passes the
already-seen track ids as exclusionList; each page returns fresh
recommendations that don't repeat earlier ones. The pageParam carries
the accumulated exclusion list. The hook keeps its existing return shape
(tracks-only lineup), so feed-page consumers are unchanged.
Swap back to getUserForYouFeed() once the new endpoint is deployed.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
🦋 Changeset detectedLatest commit: 244da8d The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
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 |
Contributor
Author
|
Folding this into #14446 to keep the For You feed fixes in one PR. Superseded by the second commit there. |
Contributor
🌐 Web preview readyPreview URL: https://audius-web-preview-pr-14448.audius.workers.dev Unique preview for this PR (deployed from this branch). |
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.
Problem
The For You feed tab is empty in production. It calls the new
GET /v1/users/{id}/feed/for-youendpoint (sdk.users.getUserForYouFeed()), which 404s on the current validator-node deployment and won't be fixed for ~a week.Fix
Point
useForYouFeedatGET /v1/tracks/recommended(sdk.tracks.getRecommendedTracks) — the long-standing, personalized recommendation source the Explore page used before the For You feed existed. It reliably returns 200 fromapi.audius.cotoday (verified:for-you→ 404 on the old fleet,/tracks/recommended→ 200).Pagination
/tracks/recommendedhas nooffsetparameter, but it does accept anexclusionList. Pagination now passes the accumulated already-seen track ids as the exclusion list, so each page returns fresh recommendations without repeats. ThepageParamcarries that list.Compatibility
The hook keeps its existing return shape (a tracks-only
LineupData[]plus derivedtrackIds), so the feed-page consumers (FeedPageContentweb desktop/mobile, mobileFeedScreen) are unchanged.This is a temporary fallback — revert to
getUserForYouFeed()once the dedicated endpoint is deployed (NOTEcomment in the hook calls this out).Test plan
tsc --noEmitpasses for@audius/commonhttps://api.audius.co/v1/tracks/recommended?limit=3returns200🤖 Generated with Claude Code