Chromecast episode and mirror actions fail on later seasons due to a global episode index
I maintainer di solito rispondono entro 2 giorni
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 78/100
Direzione di ricerca
Leggi ResultViewModel2.postEpisodes, il raggruppamento per stagione o doppiaggio e la chiamata a startChromecast che passa result.index insieme a eps; poi controlla il controllo dei limiti di CastHelper.startCast. Ricava la posizione dell’episodio selezionato nell’elenco di stagioni fornito tramite ID e ritorna in sicurezza se è assente. Il lavoro è completato quando Cast episode e Cast mirror caricano l’episodio selezionato dalle stagioni successive.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Steps to reproduce
- On CloudStream 4.8.0-pre, open a show with multiple available seasons and playable Cast links.
- Connect to a Chromecast using the app's standard Cast button.
- Use Cast episode or Cast mirror on the first available season: playback starts.
- Select a later season and repeat, choosing an episode whose index across all seasons is greater than or equal to the number of episodes in the selected season.
For a minimal data example, season 1 has 3 episodes and season 2 has 2 episodes. The first episode in season 2 has global index 3, but its position in the season's Cast list is 0.
Expected behavior
The selected episode starts playing on the Chromecast, regardless of which season is selected.
Actual behavior
The TV remains on the receiver logo. No loading indicator or playback appears. The Cast helper returns before sending a media load request.
Cloudstream version and commit hash
Reported on 4.8.0-pre. The original installed build's exact commit was not recorded. The code path was verified and the fix built against ad44a64f0cd660433ffc84994369c13336ae4015.
Android version
Not recorded by the reporter.
Logcat
Not available. The failure is explained by the index mismatch below, and the reporter has confirmed the patched APK works on the same device.
Root cause
ResultViewModel2.postEpisodes assigns ResultEpisode.index before grouping episodes by season. startChromecast passes that global result.index together with eps, which contains only the currently selected season/dub group's episodes.
CastHelper.startCast returns false when currentEpisodeIndex >= episodes.size, before sending a load command. If the global index happens to fit inside the season list, it can instead select metadata for a different episode.
Fix and validation
Resolve the selected episode by ID in eps, and pass that list position to startCast. Return safely if the episode is absent.
- Minimal source patch
- Patched APK, full corresponding source and checksums
- The reporter confirmed the patched APK resolves the issue on their device.
- Release APK compilation succeeded; all 8 existing app unit tests passed. Those tests cover subtitle selection, not this Cast scenario.
The test APK uses a separate package and signing certificate for side-by-side installation. The proposed upstream patch changes only the episode index passed to Cast.
Acknowledgements
- The failure is in the application's Cast episode selection.
- Existing issues and pull requests were searched; no matching season-index report was found.
- Lingua principale
- Kotlin
- Stelle
- 11k
- Fork
- 1.1k
- Merge medio
- 3g 5h
- PR unite (30g)
- 14
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di recloudstream/cloudstream
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
recloudstream/cloudstream#3272 ·
I maintainer di solito rispondono entro 2 giorni
-
Add new fonts for subtitlesApertaenhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
recloudstream/cloudstream#3100 ·
I maintainer di solito rispondono entro 2 giorni
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
recloudstream/cloudstream#2639 · 1 commento · 1 reazione ·
I maintainer di solito rispondono entro 2 giorni
-
enhancement
Difficoltà 3/5 1-2 giorni Idoneità per principianti 38/100
recloudstream/cloudstream#3280 ·
I maintainer di solito rispondono entro 2 giorni
-
Cast DRM links with license URL and headers via the Default Media Receiver with DRM (A12D4273)Apertaenhancement
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
recloudstream/cloudstream#3278 ·
I maintainer di solito rispondono entro 2 giorni
Tutte le issue di recloudstream/cloudstream
Issue simili
-
bug iOS UI
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
devsoc-unsw/freerooms-mobile#278 ·
-
needs-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
home-assistant/android#7690 ·
I maintainer di solito rispondono entro 1 giorno
-
staticAssetsPath follows symlinks outside the directory on WindowsForse già presa @ybelMekk l’ha presa oggi. Apertabug security findings
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
navikt/mock-oauth2-server#1132 ·
I maintainer di solito rispondono entro 1 giorno
-
performance solver
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno