Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Provider tests wait on PagedFlow's real-time retry backoff (~40 s per iOS run)

Aperta
#1,071 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
Mezza giornata
Idoneità per principianti
68/100
Tipo di issue
Refactoring
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
kotlin
Ambito
testing

Direzione di ricerca

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.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

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-36 sets MAX_ATTEMPTS=3 and BACKOFF_BASE_MS=1_000L, and delay(wait) runs at :63.
  • PlexMediaProviderTest.kt:562, and the matching helpers in the Emby (:664) and Jellyfin (:668) tests, collect the flow under runBlocking { 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.

Lingua principale
Kotlin
Stelle
229
Fork
28
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di timusus/Shuttle2

Tutte le issue di timusus/Shuttle2

Issue simili

Altre issue su Kotlin

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.