Jump to content

kodi nfo problem


ecks669
Go to solution Solved by bozrdnag,

Recommended Posts

ecks669

Since one of the latest updates the episode order in kodi is wrong. It seems random on the shows that it happens too.

 

This isnt a kodi problem as If I hit refresh on a tv show in metadata manager it fixes it. However this doesnt work on some shows and the order is wtill wrong (ep 4 before ep1 etc).

 

I was looking to what it could be and it seems there is something wrong with the nfo files. On 1 show I have where the refresh doesnt fix it, I checked the nfo files and they are not consistent with each other. 

 

This is from the show where ep4 is showing before ep 1

 

This is nfo for ep 1 and also all nfos except ep 4, all have -1 except for the dvd tags which appear to be correct in all of them

  <airsbefore_episode>-1</airsbefore_episode>
  <displayepisode>-1</displayepisode>
  <airsbefore_season>-1</airsbefore_season>
  <displayseason>-1</displayseason>
  <DVD_episodenumber>1</DVD_episodenumber>
  <DVD_season>1</DVD_season>
  <absolute_number>1</absolute_number>
  <displayepisode>-1</displayepisode>
  <displayseason>-1</displayseason>
  <displayepisode>-1</displayepisode>
  <displayseason>-1</displayseason>
  <displayepisode>-1</displayepisode>
  <displayseason>-1</displayseason>
  <displayepisode>-1</displayepisode>
  <displayseason>-1</displayseason>
  <displayepisode>-1</displayepisode>
  <displayseason>-1</displayseason>
  <displayepisode>-1</displayepisode>
  <displayseason>-1</displayseason>
  <displayepisode>-1</displayepisode>
  <displayseason>-1</displayseason>
  <displayepisode>-1</displayepisode>
  <displayseason>-1</displayseason> 

Then in ep 4 it has this

  <airsbefore_season>1</airsbefore_season>
  <displayseason>1</displayseason>
  <DVD_episodenumber>4</DVD_episodenumber>
  <DVD_season>1</DVD_season>
  <absolute_number>4</absolute_number>
  <displayseason>1</displayseason>
  <displayseason>1</displayseason>
  <displayseason>1</displayseason>
  <displayseason>1</displayseason>
  <displayseason>1</displayseason>
  <displayseason>1</displayseason>
  <displayseason>1</displayseason>

I think this is whats causing the wrong ep order, nfo files are not being written properly.

 

This is the same for a bunch of other shows

 

 I am running emby server Version 3.0.6060.0 on windows server 2012

 

Thanks

Edited by ecks669
Link to comment
Share on other sites

Try saving one of those items again. the duplicate values in the nfo has been resolved in the latest release.

Link to comment
Share on other sites

ecks669

OK I just saved it again, same thing with duplicated tags and also they are incorrect with -1 as the value. It seems random on which episodes get wrong data, like that ep 4 i saved it again and that one appears to have correct values apart from the duplicate tags.

Link to comment
Share on other sites

Thanks I will have to double check. Maybe it's not in the stable server yet and just in beta/dev, but I did fix that. 

Link to comment
Share on other sites

ecks669

Also just to add the episode order in the emby web interface is fine, its just the episode information it syncs to the emby for kodi client.

Link to comment
Share on other sites

Angelblue05

So in the webclient, the episode has an episode number filled in the metadata manager? (Not the nfos, in the metadata manager - episode number/season field)

 

 

Sent from my iPhone using Tapatalk

Link to comment
Share on other sites

Angelblue05

Emby for Kodi doesn't use the nfos. It queries straight from the server for info. Have you tried doing a repair sync to see if it fixes the episode ordering? Launch emby for kodi > repair sync.

 

 

Sent from my iPhone using Tapatalk

Link to comment
Share on other sites

We only recently started writing displayseason and displayepisode to nfo, so it might not be perfect yet.

Link to comment
Share on other sites

ecks669

Ok then the problem is not related to the malformed nfos, but the kodi episode order is wrong. Yes ive tried repair, manual sync and even reset the entire database and still the wrong episode order. I get this  same episode order on multiple devices, so the problem is not on kodis end but on what emby is syncing to it. This only started recently after 1 of the updates not exactly sure when exactly.

Link to comment
Share on other sites

ecks669

OK I just tested by manually editing the nfo for ep 1 to remove all duplicates and replaced the relevant section with this

  <airsbefore_season>1</airsbefore_season>
  <displayseason>1</displayseason>
  <DVD_episodenumber>1</DVD_episodenumber>
  <DVD_season>1</DVD_season>
  <absolute_number>1</absolute_number>

That seemed to fix it as episode 1 is now showing before ep 4 so I guess the nfos are somehow related to the info it sends to kodi

Edited by ecks669
  • Like 1
Link to comment
Share on other sites

ecks669

Another probem is I cant change the date added on an episode, doesnt let me change time only date. If I manually change the time in the nfo file nothing happens emby doesnt update the new value. I cant even change if I delete nfo and refresh, it seems to remember what the date originally was and it sets it to that again. I had to delete the series folder wait until emby scanned and deleted the show then put the folder back and it was added with the correct dateadded values.

 

Should any manually changed values in the nfo file update in emby, it seemed to work when I fixed the episode order but not for dateadded. Which values can be updated through the nfo

 

I have a feature request for the date added option in library advanced, can you add another option to use the file modified time instead of the file creation time. The file modified time is easier to change then the creation time.

 

Thanks

Link to comment
Share on other sites

If I manually change the time in the nfo file nothing happens emby doesnt update the new value.

 

Thanks

 

yes it does. you probably just didn't wait long enough, but either the library monitor or next library scan will pick it up. you can edit any value in nfo and the server will pick it up.

Link to comment
Share on other sites

ecks669

thats good to know thanks, any idea about the wrong episode order has this been fixed a in a beta or dev branch or what I can do to fix it as there are a ton of episodes where they are out of order in kodi and it would be a pain to edit each nfo manually

Link to comment
Share on other sites

ecks669

I just tested editing the dateadded in the nfo it updated the first to an older time, then I put it back to its original time and it wont switch back now. I even ran a library scan and still no change in dateadded.

 

However other changes are getting picked up, like I changed title a few times in the same nfo and they always got picked up. It seems its the dateadded thats not getting picked up.

Link to comment
Share on other sites

ecks669

I left the format exactly the same and only changed hour from

<dateadded>2016-08-16 22:43:05</dateadded>

to this

<dateadded>2016-08-16 10:43:05</dateadded>

Doesnt always seem to work, maybe it expects the date to be changed as well and doesnt consider only the time to be a change.

 

In the same nfo I changed the title everytime to make sure that emby was reading the new nfo and it was changing the title fine just not the time 

Edited by ecks669
Link to comment
Share on other sites

I guess i need to understand this a  little more because the server is only writing the information it has in it's database. For displayseason, it's getting that value from the "Airs after season" number that is available in the metadata editor. if that is empty then it uses the "airs before season number", and if that is empty then it takes the original season number from the file.

 

For displayepisode, we are using "airs before episode" and if that is blank then we don't write any value.

 

Should we be using something else for these values? You're telling me the values are incorrect, and I'm telling you we're only writing the values that are coming from your metadata, which we might have pulled from tvdb.

 

So before I can change anything, i need to know what it is you're expecting, and then where we're going to get it from.

Link to comment
Share on other sites

ecks669

ok the problem is that the information that is in the metadata manager is correct but it doesnt match what it writes to the nfo. So I dont know where this data is coming from, but somewhere it has wrong values. This is in turn leads to the problem with kodi where it is syncing episode information that matches the nfo and not the metadata manager. As you have stated kodi doesnt directly use the nfos when syncing but those incorrect values are coming from somewhere and thats what is being sent to kodi. Another thing is this only happened with old episodes I already had before a certain server update, so new episodes being added have the correct information and is being synced to kodi fine. 

 

As I stated in an earlier post if I manually edit the nfo it fixes the information being sent to kodi even though it is the same information already in the metadata manager. So it appears nothing changed from the metadata manager, but internally something got updated that made it properly sync with kodi. I cant manually update all nfo files as there are too many, so I tried completely deleting the nfo files and hitting refresh but it still didnt fix the kodi sync and its still saving with incorrect -1 values. So im not sure how to fix all the incorrectly synced episodes with kodi.

Edited by ecks669
Link to comment
Share on other sites

try to fix it instead with the metadata manager so that we can figure out what goes where. thanks.

Link to comment
Share on other sites

Angelblue05

@@ecks669 can you confirm Kodi has no sources pointing to your content? If so, remove them because then, this is your issue.

 

Trust me, the add-on doesn't send any information to the server that would effect the nfo like this. The server provides the info and that is what we write to the Kodi database. Now, you could try doing a reset in the add-on so it will remove and re-add all of your content. Launch emby for kodi > reset local database. Then restart and let it go thru the process. This will rewrite all the metadata info the server has, into Kodi.

 

 

Sent from my iPhone using Tapatalk

Edited by Angelblue05
Link to comment
Share on other sites

ecks669

Yes im positive there are no sources except the emby for kodi addon and ive tried all the emby options (manual sync, repair and reset). The wrong order stays the same and as Ive mention I have various devices using emby for kodi and they all have the same wrong episode order.

 

 

Trust me, the add-on doesn't send any information to the server that would effect the nfo like this.

 

Youve misunderstood me, I know the addon doesnt send anything to the server. Im saying the server is sending wrong information to kodi.

 

I have figured out what the problem on the emby server is. I did as you asked and edited the problem episodes in the metadata manager and when I save it, it updates the episode and season tags fine everytime. Which is why in kodi even though the episode order is wrong, it shows the correct episode number.

 

Here is where the problem begins on the emby server side, It must have been on one of the server updates or a scan it added incorrect tags (airsbefore_episode, displayepisode, airsbefore_season, displayseason) with incorrect -1 values. This information is syncing to kodi and thats where the wrong episode order comes in. Now when I save those episodes through the metadatamanager those tags stay with -1 and all it does is keep adding duplicates of (displayepisode and displayseason) with the same -1 values. So there is currently no way to fix from the metadatamanager as it just rewrites the same incorrect tags and doesnt fix them.

 

If I manually remove those 4 problem tags (and any duplicates) from the nfo which are not required since episode and season are written fine by emby. Then it only adds displayseason, but this time with the correct season number, and every subsequent save just keeps adding that same tag so youd have as many duplicates of displayseason as many times as you saved it.

 

So basically emby is syncing all the display* tags to kodi which gives the wrong episode order, but emby metadata manager does not fix it on refresh/save, just readds the wrong value to nfo. So there is nothing that can be done from within emby to fix it.

Link to comment
Share on other sites

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...