Repository navigation
Conversation
cooltey
requested review from
Williamrai,
dbrant and
voyagerfan
as code owners
October 22, 2026 22:51
This reverts commit 2ac8641.
…the week. (#7047) * Helper class for getting the weekly most read article * Optimize the helper class
* Restore commit * Update for the exp 2 * Update test name
…ia/apps-android-wikipedia into notificationsExperimentV2_design
* update notification category with weekly most read * remove comment
…tion (#7090) * Add permission check for the eligible check * More clean up from v1 * Put some other logic for the notification * Some more implementation * Update title and helper * Change extras for events * Add deny list * Add more abtest logic and also additional logic to make sure the notifications are sent * Update to "trending" for instrumentation * Address code review comments * use articleTitle instead
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Redirect handling can select non-articles or the wrong top-ranked article, while swallowed transient pageview failures can prevent retries and lose the weekly notification.
3 open issues
What changed in this PR
Replaces the recommended-reading-list notification experiment with a weekly most-read experiment, using aggregated pageviews and the existing Top Read screen.
Changes:
- Adds weekly notification scheduling, background fetching, and article ranking.
- Updates experiment eligibility, remote configuration, developer controls, and notification analytics.
- Removes V1 reading-list behavior and restores configurable update frequency.
| File | Description |
|---|---|
app/src/test/java/org/wikipedia/readinglist/recommended/RecommendedReadingListNotificationManagerTest.kt |
Removes the existing weekly scheduling tests. |
app/src/main/res/xml/developer_preferences.xml |
Switches developer controls to weekly most-read notifications. |
app/src/main/res/values/strings.xml |
Adds notification and channel text for V2. |
app/src/main/res/values/preference_keys.xml |
Replaces V1 preference keys with V2 keys. |
app/src/main/res/values-qq/strings.xml |
Updates notification localization documentation. |
app/src/main/java/org/wikipedia/settings/RemoteConfig.kt |
Adds V2 enablement and language settings. |
app/src/main/java/org/wikipedia/settings/Prefs.kt |
Stores V2 scheduling preferences and removes V1 overrides. |
app/src/main/java/org/wikipedia/settings/dev/playground/NotificationsExperimentTimePickerDialog.kt |
Returns selected trigger times through a callback. |
app/src/main/java/org/wikipedia/settings/dev/DeveloperSettingsPreferenceLoader.kt |
Connects the time picker to V2 scheduling. |
app/src/main/java/org/wikipedia/readinglist/recommended/RecommendedReadingListSettingsViewModel.kt |
Removes experiment-specific frequency visibility state. |
app/src/main/java/org/wikipedia/readinglist/recommended/RecommendedReadingListSettingsScreen.kt |
Always displays update-frequency controls when enabled. |
app/src/main/java/org/wikipedia/readinglist/recommended/RecommendedReadingListNotificationManager.kt |
Removes V1 notification scheduling and messaging. |
app/src/main/java/org/wikipedia/readinglist/recommended/RecommendedReadingListHelper.kt |
Removes experiment-specific seed article handling. |
app/src/main/java/org/wikipedia/notifications/NotificationPollBroadcastReceiver.kt |
Handles weekly alarms and restores them after reboot. |
app/src/main/java/org/wikipedia/notifications/NotificationCategory.kt |
Adds the weekly most-read notification channel. |
app/src/main/java/org/wikipedia/notifications/experiment/WeeklyMostReadNotificationWorker.kt |
Adds network-constrained background delivery with retries. |
app/src/main/java/org/wikipedia/notifications/experiment/NotificationsExperimentHelper.kt |
Implements scheduling, pageview aggregation, filtering, and notification delivery. |
app/src/main/java/org/wikipedia/notifications/experiment/NotificationsExperimentAbTest.kt |
Switches experiment identity and eligibility to V2. |
app/src/main/java/org/wikipedia/feed/topread/TopReadFragment.kt |
Leaves screen-title selection to the activity. |
app/src/main/java/org/wikipedia/feed/topread/TopReadArticlesActivity.kt |
Supports notification navigation and a weekly title. |
app/src/main/java/org/wikipedia/dataclient/RestService.kt |
Adds the daily top-pageviews endpoint. |
app/src/main/java/org/wikipedia/dataclient/restbase/TopPageViews.kt |
Models the top-pageviews response. |
app/src/main/java/org/wikipedia/activity/BaseActivity.kt |
Schedules V2 notifications and records trending notification opens. |
Review effort: Balanced
- Only skip a day of page views on 404, so other failures reach WeeklyMostReadNotificationWorker and it can retry. - Rank each article by the best rank among its own title and every requested title that redirects to it, instead of only the last redirect. - After redirects are resolved, drop pages outside the article namespace and the main page, which namespace aliases or redirects can lead to. Co-Authored-By: Claude Opus 5.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.


Phabricator:
https://phabricator.wikimedia.org/T439763