Please add support for actor "<order>" tags in local .nfo files:

REWRITTEN because I learned something: and so I’m updating my request.

  1. Infuse recently switched to supporting/enforcing local override of TMDB cast data for all users who have local .nfo files; regardless if those files even have <cast> tags.

  2. This also applies to individual Television episodes.

  3. TMDB identifies actors as either Season Regulars or Guest Stars.

  4. TMDB further list Series Regulars and Guest Stars in a specific order, representing their precedence in the production (or studio contracts) and reflected in their names’ placement in the shows credits.

In the above link, you can see how this order can be edited on TMDB. That order is maintained by assigning each cast member a specific precedence number (for lack of the official term) for each episode in which they appear. When APIs scrape TMDB for cast information, this number is made available — it is utilized as the data for the actor tag.


This benefits users is that the stars of the show are featured most prominently in the cast & crew bar on Infuse’s details (or pre-playback) pages.

  1. Infuse must already utilize this tag when scraping TMDB natively, because I’ve never had actors appear out of order before Infuse was updated to support (force) cast overrides in the presence of local .nfo files.

  2. But if an Infuse user has .nfo tags with his files, for any reason, Infuse will no longer display cast and crew in the sensible way it does when scraping from TMDB. Instead, it will only display the first 15 cast members listed in the local .nfo file — without regard to how prominent that actor might be in that series or episode — or display none at all, if the Infuse user’s .nfo files had no <actor> tags at all, because they preferred to let Infuse & TMDB do it’s good work of keeping track of cast and crew all by itself.

  3. Since not all software solutions that create .nfo files write actors to the .nfo in the order of their precedence in the show, and because Infuse isn’t reading the accompanying actor <order> tags, users stuck in that position have found the Cast and Crew bar become a mess overnight.

  4. Fixing this won’t resolve the other issue this update caused: the creation of parallel cast databases and duplication of every cast member in one’s library … but I’ve already written about extensively in a different thread).

Two suggested solutions: (You can chose both, but at least implement one!)

  1. Expand <actor> tag support in local .nfo files to include utilizing the <order> tag.

  2. Allow users to opt out of Cast & Crew override, even if they have local .nfo files which they require for other purposes (such as altering movie titles to get around TMDB’s and Firecore’s lack of support for multiple versions and encodings) …

Thank you…

@james — Question: When reading cast tags from local .nfo, are you respecting the <order> tag?


I’m guessing since the metadata 101 file only lists the <name>, <role>, and <thumb> tags, this is a big no.

Turns out my version of Kodi wasn’t excluding the main cast members at all, but just appending them to the bottom of the long list of other actor tags.

Since Infuse seems to only show the first 15 actors listed in the .nfo file in the order they exist in the file, that now explains why all my series regulars no longer appear.

When editing a series cast members on TMDB, the option is provided to arrange their order (as they would appear on the main titles and in the credits). The result of that sorting assigns each cast member a precedence number (I don’t know what it’s officially called). But that’s what the <order> tag is for: it will make sure the biggest stars of the show appear at the top (or to the left most) of every list including the entire cast.

Since Infuse won’t show more than the first 15 actors under any circumstances, it’s that much more important that Infuse show the CORRECT fifteen.

Utilizing the tag will do that.

(I hereby drop my original request to add support for the tvshow.nfo file.)



I’ve kept digging into this and it turns out I was using a TMDB scraper that purposefully put main cast last in the episode.nfo files (though the tags were still correctly numbered). Gah!

@NC_Bullseye … you are welcome to delete this thread; or leave it up for this nugget for anyone who might need it:

I’ve been using Kodi for ages, but I only started scraping my TV shows from TMDB when I found out how much I enjoyed Infuse, and how important it was to use the same metadata provider. So I’ve scraped my entire television library anew over the past many months.

In all that time I never realized there was any significant difference in the logic behind the two default TMDB television scrapers provided with Kodi. One is called “The Movie Database (TMDB TV show Scraper)”, and the other “TMDb TV Shows (Fetch TV Show metadata from”.

But now that Infuse has stopped serving me cast and crew scraped directly from TMDB (because I use local .nfo files to alter titles to accommodate different versions and encodings), the difference has become all to clear.

The Movie Database (TMDB TV show Scraper)” — the original.
This one writes cast entries to the .nfo file in the order specified by their <order> tags.

TMDb TV Shows (Fetch TV Show metadata from” — the newer (est. 2008), python based scraper.
This one writes cast entries to the .nfo files with guest stars (and bit players) first; and the main cast last (though it keeps their <order> tags intact).

I gather this latter decision was taken because in the earlier days of TMDB, actors were marked as season regulars even for anthology shows that had a new cast each episode, and thus actors would be showing up incorrectly. It was felt putting them last would highlight the “guest star” actors who were actually specifically noted as having been in each specific episode.

So, I guess I can ditch TinyMediaManager now. At least that’s a relief. :upside_down_face:

Okay, move along, now… Nothing more to see here.

Fix the duplicate cast issue and let’s all forget all this!

1 Like

Can I wait for this to be made into a movie? The book is great but I can’t keep the cast right. :clown_face:

It may be best if you don’t mind to leave it here so others that may be questioning the nuts and bolts of how this works will benifit from your digging.

Thanks for the bulldog effort!

1 Like

The sequel is already out!

Continued testing revealed further lapses of understanding: It’s not enough just to use the old scraper. It puts cast members in correct order, yes, but it doesn’t grab them all. In many cases, it doesn’t seem to grab ANY of the guest stars. Sigh.

Turns out you actually do need to use BOTH. But in which order?
So I did a bunch more tests, and figured out the only sequence that seems to work.

So here’s what an Infuse user (namely, me) with .NFO files must do, just to get the Cast & Crew bar to display as complete and as accurately as it used to, when Infuse did it all by itself:

  1. Delete all 11,499 local episode .NFO files from my entire television library.
    *:warning:This step is important.

  2. Scan that entire television library into Kodi using the TMDb TV Shows metadata scraper (which should take about six days non-stop, give or take :sob:).

  3. Export 11,499 new episode .NFO files to disc.
    *These .NFO files will have been written with the main cast listed after the guest cast and extras.

  4. Return to the Videos - Files menu, and for each folder I imported into Kodi to scan my television library, select Change Content and then select the The Movie Database scraper.

  5. Select Yes when prompted “Do you wan to refresh information for all items in this path?

  6. Allow my entire library to be scanned again (which might take another six days :frowning_face:, or perhaps, go slightly faster :crossed_fingers:t4::grimacing: since the library has already been imported).

  7. Export 11,499 newly updated .NFO files.
    *:warning:Make sure to select Yes when prompted to “Overwrite old files?

  8. Where I need to make changes to displayed series names (for various reasons) or displayed episode titles (for shows like “Firefly” that were aired out of order and switching to DVD order is not yet supported), or for any other Infuse supported .NFO changes, or to change the invaluable <sorttitle> tag which Infuse perplexingly does not yet support … I can do that between steps 2 and 3, and/or between steps 6 and 7. Either or both will work.

  9. :warning: Change FILE NAMES at any point between beginning step 1 and the completion of step 7, and this won’t work!

So, I can do all that.

But I’ll still be saddled with duplicate results in EVERY cast or crew member search conducted via the search feature (voice or text), and cast photos that when clicked, never display that actor’s complete body of work among the titles in one’s library … because Infuse now creates two separate cast databases, but hides the better-resourced one if it detects any local .NFO files (regardless if they have <actor> tags or not).

OR, Firecore can just add this settings menu option:

Cast & Crew Data:

  • Use TMDB
  • Use Local Files
  • Use Both
    (preferably “Merge Both”)

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.