Provider tests wait on PagedFlow's real-time retry backoff (~40 s per iOS run)
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- Half a day
- Newbie friendliness
- 68/100
Research direction
Start with PagedFlow.kt lines 35-36 for the retry constants and the delay(wait) call at line 63, then read PagedFlowTest, which already uses runTest. The slow collectors are in PlexMediaProviderTest.kt near line 562 and the Emby (~664) and Jellyfin (~668) test helpers, which use runBlocking { toList() }. Run iosSimulatorArm64Test first to get a baseline timing. Done means these tests run on virtual time, the total drops well below 40 s, and Plex's real-I/O cases still pass.
Written by the indexing model from the issue text.
Description
Provider tests pay the PagedFlow retry delay on the real clock: about 40 s per iOS provider test run.
android/mediaprovider/server/src/commonMain/.../PagedFlow.kt:35-36setsMAX_ATTEMPTS=3andBACKOFF_BASE_MS=1_000L, anddelay(wait)runs at:63.PlexMediaProviderTest.kt:562, and the matching helpers in the Emby (:664) and Jellyfin (:668) tests, collect the flow underrunBlocking { toList() }, so the delays happen in real time.- Measured on
iosSimulatorArm64Test: PlexMediaProviderTest takes 24.6 s over 38 tests, and Emby and Jellyfin take 7.8 s and 7.5 s. The slow cases are the 3-4.6 s failure-path tests.
Fix: collect under runTest so delay runs on virtual time (PagedFlowTest already does this), or inject the backoff. Check that Plex's real-I/O paths still work under runTest.
Found by the codehealth measured-report experiment.
- Dominant language
- Kotlin
- Stars
- 231
- Forks
- 28
- PR merge metrics
- No merged PRs in 30d
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from timusus/Shuttle2
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100
-
support/scripts/asc: S2 bundle id resolves to the Podcasts app (bundleId filter is a prefix match)Openbug next-release
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug design impact:U1 later P3 reach:R2 size:S
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
-
enhancement impact:U1 later P3 reach:R2 size:S
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
impact:U1 owner reach:R1 size:S
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
All issues in timusus/Shuttle2
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
navikt/mock-oauth2-server#1129 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 77/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
world-federation-of-advertisers/cross-media-measurement#4709 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
mikepenz/AboutLibraries#1488 · 2 comments ·
Maintainers usually reply within 1 day