Repository navigation
feat(library): show TMDB's overview when no description gives one - #1728
Merged
Merged
Conversation
A movie, series or episode whose descriptions give no overview showed none, even with a TMDB key. With a key, its page now shows TMDB's: in the user's metadata language, else English, else the title's original language. A movie's or series' overviews come with its credits: translations are appended to the one request of its details and kept in title_credits, so they cost no request of their own; credits kept before are read again once, at a page or in the next pass. An episode's come from its season's answer in a language, kept in memory; English is the answer its guest stars read, so a season costs at most one request per other language. Listings show the descriptions' overviews only and ask TMDB nothing. Edit metadata starts from TMDB's overview, so saving the editor unchanged keeps following TMDB. Text of nothing but spaces and direction marks now counts as none: a title's or episode's overview, and every text a description in the user's language gives.
Addons tells the order an overview is taken in, what it costs per title opened, that blank texts count as none, and how Jellyfin differs; Getting started lists overviews among what a TMDB key adds.
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.
A movie, series or episode whose descriptions give no overview showed none. The server addon's description stood in for an empty overview in the user's language, but nothing filled an overview the server's addon lacks too, even with a TMDB key.
With the server's TMDB key, a title's or episode's page now shows TMDB's overview when no description gives one:
translationsjoins theappend_to_responseof the one details request that already reads their credits, studios, tagline and services. The overviews of every language and the original language are kept intitle_creditsand read again with the credits, every 30 days or on Refresh metadata. No request of their own. The overviews are read from the database only for the title shown, never with the credits listings read. Credits kept before have no overviews, so they are due again once, at a title's page or in the next pass, as when studios and services were added.Itemsby identifier and episode lists show the descriptions' overviews only. The movie or series fill reads only what is kept; the episode fill runs only from the item page.Library.Original), so saving it unchanged keeps following TMDB and stores no edit.docs/addons.md(new "Overviews no description gives" with how Jellyfin differs, and the blank texts of a description in a language),docs/getting-started.md(what a TMDB key adds).Cost per title opened: a movie or series, 0 requests (1 once for credits kept before this change, which the next pass would read anyway). An episode, 0 for an English user; 1 per season for a user of another language; 1 more per season, only when neither language has an overview, for the original language.
Upgrading: nothing to do. A migration adds two nullable columns to
title_credits; kept credits are read again once.Tests:
TestTitlesWithoutAnOverviewShowTMDBs(new): movies whose addon gives no overview get TMDB's in French (the server's language), else English, even for a Japanese original that has a Japanese overview, else the original language (Japanese); a blank addon overview, and TMDB's French of a direction mark alone, are replaced; an addon's overview stays; each movie costs its one details request, withtranslations. Fails without the fill, withouttranslationsappended, without the blank checks, and with the original language before English.TestAnEpisodeWithoutAnOverviewShowsTMDBs(new): a season in French gives the first episode's, English the second's whose addon overview is blank; each season answer is asked once with guest stars; Edit metadata starts from TMDB's. Fails without the episode fill and without the blank check.TestCreditsKeptWithoutOverviewsAreDueOnce(new): credits kept without overviews are due, a page reads them again once and shows TMDB's overview. Fails when kept rows without overviews are not due.TestAnEpisodeFallsBackToItsSeriesOriginalLanguage(new): an episode with no French nor English overview shows the one in its series' original language, that season asked once. Fails when the episode's original language is dropped.TestWithoutAKeyTMDBIsAskedNoOverview(new): no request without a key; the overviews show once a key is set, and hide again without asking once it is taken off. Fails when the fill ignores the key.TestListingsAskTMDBNoOverview(new): library children,Itemsand episode lists ask TMDB for no overview and show none; the page then does. Fails when an episode list fills overviews, and without the page's fill.TestBlankTextsInALanguageLeaveTheServers(new): blank name, overview and episode texts of a description in the user's language leave the server's. Fails with the former empty-only check.TestTitleDetailsGiveTheOverviewsOfEveryLanguage,TestOverviewsInTheFirstLanguageTMDBHasOneIn,TestAnEpisodesOverviewIsReadInALanguage(new, tmdb): translations read from the details request, blank ones left out; the language and region preference; an episode's overview shares the guest stars' answer. Fail withouttranslationsappended and without the US preference for English.TestAMoviesCreditsAreItsBilledCastAndCrew(tmdb): its pinned details request now appendstranslations.