Fix repeated DFE paging keys#122
Merged
Merged
Conversation
Treat repeated Play Store continuation URLs as the end of pagination so Paging does not receive the same nextKey twice. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR hardens DFE-based pagination in ListEndpointPagingSource by preventing Paging from receiving a repeated continuation URL as nextKey, treating that condition (and missing/blank continuations) as end-of-pagination.
Changes:
- Added a small helper (
resolveNextPageUrl) to normalize/validate the next-page continuation URL (null/blank/repeated →null). - Updated
ListEndpointPagingSource.load()to use the resolvednextKeyand improved debug logging to show requested → resolved continuation. - Added unit coverage for new/repeated/missing/blank continuation URL behavior.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| app/src/main/java/com/anod/appwatcher/search/ListEndpointPagingSource.kt | Ensures pagination stops when the server repeats or omits the continuation URL, avoiding duplicate nextKey emissions. |
| app/src/test/java/com/anod/appwatcher/search/ListEndpointPagingSourceTest.kt | Adds regression tests covering repeated, missing, and blank continuation URLs. |
Use the current v2 open source licenses activity and SDK to avoid crashes in the legacy Google licenses fragment. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add Firebase CLI and Crashlytics REST API steps for checking issue and event details from crash URLs. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Restore top-level Markdown headings and bullets for the new Crashlytics investigation instructions. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Use a Markdown-safe issue id placeholder in Crashlytics lookup instructions. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Keep Crashlytics lookup guidance generic and avoid publishing Firebase identifiers, tokens, raw logs, or private URLs. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.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.
Summary
nextKeytwice.play-services-oss-licenses:17.5.1and the v2OssLicensesMenuActivity..github/copilot-instructions.md.Crashlytics fixes checked
IllegalStateExceptionfrom AndroidX Paging because the Play Store endpoint returned the same continuation URL; fixed by treating repeated continuations as end-of-pagination.Resources$NotFoundException: Resource ID #0x0inside Google OSS licenses legacy fragment; logs did not contain an explicit settings click, so the fix updates to the current v2 licenses activity and adds an app-owned log at launch.How to check Crashlytics crashes
Validation
.\gradlew.bat :app:testDebugUnitTest --tests "com.anod.appwatcher.search.ListEndpointPagingSourceTest".\gradlew.bat :app:testDebugUnitTest.\gradlew.bat ktlintCheck.\gradlew.bat :app:assembleDebug :app:testDebugUnitTest ktlintCheck --no-daemon.\gradlew.bat --quiet :app:dependencyInsight --dependency play-services-oss-licenses --configuration releaseRuntimeClasspathresolvescom.google.android.gms:play-services-oss-licenses:17.5.1