Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add forced subtitles matching based on audio language #42

Merged
merged 1 commit into from
Jul 19, 2022

Conversation

RemiRigal
Copy link
Owner

Forced subtitles can sometimes be available only for some episodes of a show. This leads to issue in cases like this:

Subtitles for episode 1:
  - English
  - English (Forced)
Subtitles for episode 2:
  - English
Subtitles for episode 3:
  - English
  - English (Forced)

Selecting English (Forced) on episode 1 will result in PAL correctly selecting the forced subtitles for episode 3 and nothing for episode 2.
But when watching episode 2, PAL will deselect the force subtitles for episode 3, which is not the expected behavior.

This PR changes this by selecting the forced subtitles based on the language of the selected audio stream if no subtitles is selected for the current episode.

@codecov-commenter
Copy link

codecov-commenter commented May 16, 2022

Codecov Report

Merging #42 (432628e) into master (2ea8b87) will increase coverage by 2.11%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master      #42      +/-   ##
==========================================
+ Coverage   93.75%   95.86%   +2.11%     
==========================================
  Files          18       18              
  Lines         961      968       +7     
==========================================
+ Hits          901      928      +27     
+ Misses         60       40      -20     
Flag Coverage Δ
claimed 95.86% <100.00%> (+2.11%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
plex_auto_languages/track_changes.py 96.90% <100.00%> (+10.81%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2ea8b87...432628e. Read the comment docs.

@RemiRigal RemiRigal force-pushed the feat/forced_subtitles_matching branch from d09f240 to 432628e Compare May 26, 2022 06:10
@RemiRigal RemiRigal merged commit 30dceaa into master Jul 19, 2022
@RemiRigal RemiRigal deleted the feat/forced_subtitles_matching branch July 19, 2022 09:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants