Jump to content

Reading and writing of nfo for multi-part episodes is wrong


Recommended Posts

Posted
2 minutes ago, VirulentPip said:

Did this ever become a thing? Found this thread while trying to figure out if possible to have it show

1-2 Boara Boara - Saskatchewan Catch

On a tropical island, Timon and Pumbaa run into The Three Natives who make Pumbaa their god-king and try to kill Timon for intending to "abduct" him. Timon & Pumbaa help a female flying squirrel find love in return for her fetching them some Saskatchewan tree beetles.

image.png.779baade040dd3b0b81276392b0abf02.png

Hi, it will when pulled from internet metadata. I think the nfo reader might still only read the first episode though, so that's an area that needs to be improved. Thanks.

  • Thanks 1
  • 1 month later...
sydlexius
Posted

@Luke, just adding my voice to this.  I hope you guys can take some time to look into this.  Is there any reason why Emby couldn't correctly parse an NFO with multiple root <episodedetails> tags?

Posted
3 minutes ago, sydlexius said:

@Luke, just adding my voice to this.  I hope you guys can take some time to look into this.  Is there any reason why Emby couldn't correctly parse an NFO with multiple root <episodedetails> tags?

It's just something that hasn't been looked at yet. Thanks.

  • 8 months later...
darkside40
Posted
On 9/7/2022 at 8:14 PM, Luke said:

Hi, it will when pulled from internet metadata. I think the nfo reader might still only read the first episode though, so that's an area that needs to be improved. Thanks.

So when will this happen?

Posted
3 hours ago, darkside40 said:

So when will this happen?

Hi, no eta but it is in our plans. Thanks.

darkside40
Posted

Is there a valid nfo structure for this that the NFO reader can actually read?

I mean if i look at the NFO's Emby generated for Milo Murphy that might be possible if Emby could reread them.

Than it might be an idea to write some kind of conversion script to overcome that issue.

sydlexius
Posted
2 hours ago, darkside40 said:

Is there a valid nfo structure for this that the NFO reader can actually read?

I mean if i look at the NFO's Emby generated for Milo Murphy that might be possible if Emby could reread them.

Than it might be an idea to write some kind of conversion script to overcome that issue.

I've done some digging into this, and the de facto "standard" for NFOs is not fully XML-compliant.  Emby's NFO parser is stricter in how it handles these files, and needs to "loosen up", as well as having routines added to manually parse multi-EP files.  For the LOLs, I created a POC C# .NET-based parser to handle these files some time ago based on assumptions I'd had about how Emby may have been reading these files. With that said:

  1. I don't know diddly squat about C#
  2. My assumptions could have been wildly wrong
  3. My test cases were only a few multi-EP files, so it's entirely possible there are edge cases that would break it
  4. My code did zero error-handling

All of this is to say that it's possible to do, but most likely isn't that trivial to implement correctly.  With that said, I'm hoping a solution is forthcoming because of all of the kids shows that I serve!

Posted
1 hour ago, sydlexius said:

I've done some digging into this, and the de facto "standard" for NFOs is not fully XML-compliant.  Emby's NFO parser is stricter in how it handles these files, and needs to "loosen up", as well as having routines added to manually parse multi-EP files.  For the LOLs, I created a POC C# .NET-based parser to handle these files some time ago based on assumptions I'd had about how Emby may have been reading these files. With that said:

  1. I don't know diddly squat about C#
  2. My assumptions could have been wildly wrong
  3. My test cases were only a few multi-EP files, so it's entirely possible there are edge cases that would break it
  4. My code did zero error-handling

All of this is to say that it's possible to do, but most likely isn't that trivial to implement correctly.  With that said, I'm hoping a solution is forthcoming because of all of the kids shows that I serve!

It has nothing to do with strictness. It’s more about  what we’re going to do with the data, and then how it would be written back to the nfo.

sydlexius
Posted
2 hours ago, Luke said:

It has nothing to do with strictness. It’s more about  what we’re going to do with the data, and then how it would be written back to the nfo.

I would assume that you'd not have much choice other than to generate a "buggy" file so it can be compatible with other solutions (not necessarily media servers)?

Posted
2 hours ago, sydlexius said:

I would assume that you'd not have much choice other than to generate a "buggy" file so it can be compatible with other solutions (not necessarily media servers)?

In the server database it's one episode, so it would all get merged on the import with no way to split it back when the nfo gets saved. So basically, if we only add support to read the multiple episode details, then that will be the next thing that you report an issue on. So the first part of this is easy. The second part will require more dramatic changes.

sydlexius
Posted
2 hours ago, Luke said:

In the server database it's one episode, so it would all get merged on the import with no way to split it back when the nfo gets saved. So basically, if we only add support to read the multiple episode details, then that will be the next thing that you report an issue on. So the first part of this is easy. The second part will require more dramatic changes.

I assume that whatever the final form looks like, end-users are probably going to have to refresh the metadata for each impacted library?

Posted
35 minutes ago, sydlexius said:

I assume that whatever the final form looks like, end-users are probably going to have to refresh the metadata for each impacted library?

That's probably a good bet.

  • 3 months later...
GrimReaper
Posted

Since NFOs handling seems to be getting some lovin' in beta cycle lately, any progress made on this subject, maybe? 

  • 3 months later...
Posted

This is going to be much improved very soon - in 4.9.0.6 beta and backported to the 4.8.2 maintenance release.

The nfo handling will be improved to work with the database that we have, meaning:

  • Nfo reading will merge the metadata from multiple episodedetails elements in the nfo file
  • Nfo saving will attempt to split the values back into separate episodedetails nodes when writing the nfo file

It's important to note though that most of the metadata will be duplicated across all of the episodedetail nodes, but this will at least provide greater compatibility with other nfo software.

  • Like 2
  • Thanks 2
sydlexius
Posted (edited)

@Luke Thank you! I assume I'll need to refresh metadata on the impacted shows, or will a mere library scan suffice?

Edited by sydlexius
Stupid swiftkey
Posted
10 hours ago, Luke said:

This is going to be much improved very soon - in 4.9.0.6 beta and backported to the 4.8.2 maintenance release.

The nfo handling will be improved to work with the database that we have, meaning:

  • Nfo reading will merge the metadata from multiple episodedetails elements in the nfo file
  • Nfo saving will attempt to split the values back into separate episodedetails nodes when writing the nfo file

It's important to note though that most of the metadata will be duplicated across all of the episodedetail nodes, but this will at least provide greater compatibility with other nfo software.

Just to clarify, this will write intro data into nfos?

Posted
51 minutes ago, Edrock200 said:

Just to clarify, this will write intro data into nfos?

No idea  what you’re asking.

Posted
21 hours ago, Luke said:

No idea  what you’re asking.

Apologies. I thought this was the intro detection thread. 

  • Thanks 1
Happy2Play
Posted

@Lukeused the example from first post.  All providers disabled to test.

Looks like a winner.

image.thumb.png.b8d84ec6ce68fb311a0795df5fa58df8.png

copied nfo

Spoiler

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<episodedetails>
    <imdbid></imdbid>
    <title>Die magische Flöte</title>
    <showtitle>Disneys Gummibärenbande</showtitle>
    <rating>7.3</rating>
    <votes>4</votes>
    <top250>0</top250>
    <season>1</season>
    <episode>4</episode>
    <plot>Sunni kann das Fiepen von Cubbis Blechflöte nicht mehr hören und verbiegt sie. Daraufhin kommt ein Ton heraus, der eine riesige fliegende Schlange herbeiruft.</plot>
    <outline>Sunni kann das Fiepen von Cubbis Blechflöte nicht mehr hören und verbiegt sie. Daraufhin kommt ein Ton heraus, der eine riesige fliegende Schlange herbeiruft.</outline>
    <mpaa>FSK 0</mpaa>
    <playcount>0</playcount>
    <lastplayed></lastplayed>
    <aired>1985-09-28</aired>
    <studio>Playhouse Disney</studio>
    <thumb>https://thetvdb.com/banners/episodes/76081/182544.jpg</thumb>
    <fileinfo>
        <streamdetails>
            <video>
                <durationinseconds>1338</durationinseconds>
                <codec>avc</codec>
                <aspect>1.333</aspect>
                <width>960</width>
                <height>720</height>
                <scantype>progressive</scantype>
            </video>
            <audio>
                <language>deu</language>
                <codec>AC-3</codec>
                <channels>2</channels>
            </audio>
        </streamdetails>
    </fileinfo>
</episodedetails>
<episodedetails>
    <imdbid></imdbid>
    <title>Der einsame Drache</title>
    <showtitle>Disneys Gummibärenbande</showtitle>
    <rating>7</rating>
    <votes>8</votes>
    <top250>0</top250>
    <season>1</season>
    <episode>5</episode>
    <plot>Tummi und Zummi entdecken ein seltsames Gummi-Gefährt, das sich als Drachen-Aufspür-Gerät entpuppt. Prompt weckt Tummi einen Drachen auf: aber der ist nicht zum Fürchten, sondern nur einsam.</plot>
    <outline>Tummi und Zummi entdecken ein seltsames Gummi-Gefährt, das sich als Drachen-Aufspür-Gerät entpuppt. Prompt weckt Tummi einen Drachen auf: aber der ist nicht zum Fürchten, sondern nur einsam.</outline>
    <mpaa>FSK 0</mpaa>
    <playcount>0</playcount>
    <lastplayed></lastplayed>
    <aired>1985-09-28</aired>
    <studio>Playhouse Disney</studio>
    <thumb>https://thetvdb.com/banners/episodes/76081/331216.jpg</thumb>
    <fileinfo>
        <streamdetails>
            <video>
                <durationinseconds>1338</durationinseconds>
                <codec>avc</codec>
                <aspect>1.333</aspect>
                <width>960</width>
                <height>720</height>
                <scantype>progressive</scantype>
            </video>
            <audio>
                <language>deu</language>
                <codec>AC-3</codec>
                <channels>2</channels>
            </audio>
        </streamdetails>
    </fileinfo>
</episodedetails>

 

  • Thanks 1
Posted
Just now, Happy2Play said:

@Lukeused the example from first post.  All providers disabled to test.

Looks like a winner.

image.thumb.png.b8d84ec6ce68fb311a0795df5fa58df8.png

copied nfo

  Reveal hidden contents

 

Thank you !

Posted

@pünktchenare you enjoying seeing multiple episodedetails nodes in your nfo files now?

Posted

If I delete a multi-episode show, re-create the nfo, and scan the show back into my emby library should I see the multi-episode correctly in emby?  If so then media companions multi-episode format must not work with emby's.

Happy2Play
Posted
4 hours ago, worthmo said:

If I delete a multi-episode show, re-create the nfo, and scan the show back into my emby library should I see the multi-episode correctly in emby?  If so then media companions multi-episode format must not work with emby's.

Not sure I follow the question as I have already added a multi episodedatail nfo to Emby and it was readd as shown above.

Posted (edited)

I'm using Media Companion to create NFO files.  It appears that multi-episodes do not work with this tool.  What tools are others using to create NFO files?

image.png.7c6a88842b11fad44317d67daba382a1.png

image.png.5e6b147f97db6132d5b987bf3f26bb7d.png

Edited by worthmo
Happy2Play
Posted
1 hour ago, worthmo said:

I'm using Media Companion to create NFO files.  It appears that multi-episodes do not work with this tool.  What tools are others using to create NFO files?

image.png.7c6a88842b11fad44317d67daba382a1.png

image.png.5e6b147f97db6132d5b987bf3f26bb7d.png

And your library settings?  But will guess nfo reading is not enabled.

If settings are correct then can you post a copy of the nfo file.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...