Alternative sorting of series with tmdb scraper
#1
Hello,

I have tried it with issue on github but it seems it was misplaced there.
So I hope someone here can help me or fulfill my wish Wink

Here is my Problem:
With the scraper for The Movie Db (tmdb) it is not possible to select an alternative sorting for the default sorting.
In my specific case, I would like to switch from "Original Air Date" to "German Broadcast (TV)" for the series Case Closed. However, this is currently not possible.
Here is a link to the page:
https://www.themoviedb.org/tv/30983-case...uage=en-EN

For individual series or at least generally it should be possible to select an alternative sorting.

Can someone (maybe the developer of this scraper) can do this, or give me another solution.
But the solution should not be to have to rename everything Wink

Thanks in advance for your help.
Reply
#2
Episode Groups are supported with version 3.1.0 of the scraper, available for Kodi v18 (Leia). 
The scraper works fine on v17 (except for the parts that don't do anything, but they don't interfere).  It just hasn't yet been backported, and it will be after Christmas at this point before I get to it.

The way to get it to work is to make a tvshow.nfo file in the folder of the show, with the contents of the file just being the URL of the episode group you want to use.
In your case that would be:

Code:
https://www.themoviedb.org/tv/30983-case-closed/episode_group/5afdcddd92514127a0001878

Note, this assumes that your files are numbered according to the episode group, i.e. "Staffel 1" is season 1, with 96 episodes (S01E01-S01E96), "Staffel 2" is season 2 (S02E01-S02E75), etc.
It DOES NOT take files numbered according to the original broadcast order and sort them into the episode group ordering.  This is not possible.
A file numbered S01E97 will be ignored, it won't be interpreted as S02E01.

If you choose to refresh the series in Kodi at any point, remember to NOT ignore local information.
Reply
#3
(2018-12-20, 14:41)scudlee Wrote: Episode Groups are supported with version 3.1.0 of the scraper, available for Kodi v18 (Leia). 
Oh, that is great. That was a well hidden new feature Wink
My Signature
Links to : Official:Forum rules (wiki) | Official:Forum rules/Banned add-ons (wiki) | Debug Log (wiki)
Links to : HOW-TO:Create Music Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#4
This sounds good Big Grin
But I will give the nfo file a chance too.
Reply
#5
(2018-12-20, 22:13)draester Wrote: This sounds good Big Grin
But I will give the nfo file a chance too.
The NFO file is the new feature.

EDIT: Just tried it with Firefly and it worked perfectly, thanks.
Reply
#6
(2018-12-20, 14:41)scudlee Wrote: Episode Groups are supported with version 3.1.0 of the scraper, available for Kodi v18 (Leia). 
The scraper works fine on v17 (except for the parts that don't do anything, but they don't interfere).  It just hasn't yet been backported, and it will be after Christmas at this point before I get to it.

The way to get it to work is to make a tvshow.nfo file in the folder of the show, with the contents of the file just being the URL of the episode group you want to use.
In your case that would be:

Code:
https://www.themoviedb.org/tv/30983-case-closed/episode_group/5afdcddd92514127a0001878

Note, this assumes that your files are numbered according to the episode group, i.e. "Staffel 1" is season 1, with 96 episodes (S01E01-S01E96), "Staffel 2" is season 2 (S02E01-S02E75), etc.
It DOES NOT take files numbered according to the original broadcast order and sort them into the episode group ordering.  This is not possible.
A file numbered S01E97 will be ignored, it won't be interpreted as S02E01.

If you choose to refresh the series in Kodi at any point, remember to NOT ignore local information.
This sounds amazing and is exactly what I want/need. The problem is I can't get it to work. For example I'm trying this on Futurama atm. I put the "Futurama (1999).nfo" file into the directory where my episodes are all. they are named and numbered according to the production order. i put the direct link to that in the .nfo file and nothing else. I tried refreshing and freshly scanning the series and pressed "no" when asked to ignore local information. what am i doing wrong? i have the right version of the scraper and the right version of kodi, i checked both. it only worked once when testing when i only put the first season plus the first episode of the 2nd season in the folder when i initially saw this post. but since i have the complete series there i cant get it to work sadly. dont know what i did different. also tried naming the .nfo file just "tvshow.nfo" but i assume naming it like the show is the right way... thanks for every help!
Reply
#7
(2019-10-19, 04:48)Vogeluff Wrote:
(2018-12-20, 14:41)scudlee Wrote: Episode Groups are supported with version 3.1.0 of the scraper, available for Kodi v18 (Leia). 
The scraper works fine on v17 (except for the parts that don't do anything, but they don't interfere).  It just hasn't yet been backported, and it will be after Christmas at this point before I get to it.

The way to get it to work is to make a tvshow.nfo file in the folder of the show, with the contents of the file just being the URL of the episode group you want to use.
In your case that would be:

Code:
https://www.themoviedb.org/tv/30983-case-closed/episode_group/5afdcddd92514127a0001878

Note, this assumes that your files are numbered according to the episode group, i.e. "Staffel 1" is season 1, with 96 episodes (S01E01-S01E96), "Staffel 2" is season 2 (S02E01-S02E75), etc.
It DOES NOT take files numbered according to the original broadcast order and sort them into the episode group ordering.  This is not possible.
A file numbered S01E97 will be ignored, it won't be interpreted as S02E01.

If you choose to refresh the series in Kodi at any point, remember to NOT ignore local information.
This sounds amazing and is exactly what I want/need. The problem is I can't get it to work. For example I'm trying this on Futurama atm. I put the "Futurama (1999).nfo" file into the directory where my episodes are all. they are named and numbered according to the production order. i put the direct link to that in the .nfo file and nothing else. I tried refreshing and freshly scanning the series and pressed "no" when asked to ignore local information. what am i doing wrong? i have the right version of the scraper and the right version of kodi, i checked both. it only worked once when testing when i only put the first season plus the first episode of the 2nd season in the folder when i initially saw this post. but since i have the complete series there i cant get it to work sadly. dont know what i did different. also tried naming the .nfo file just "tvshow.nfo" but i assume naming it like the show is the right way... thanks for every help! 

edit: now it works... changed it to "tvshow.nfo" AGAIN. dont know why it didnt work before. thanks anyway this is a great solution!
Reply
#8
This is really great — glad to discover it.

However, in case anyone comes here trying to reverse this procedure ... it's not as easy as just removing the "tvshow.nfo" file with the link to the DVD order, or redirecting that link to the original page, or removing the show from your library and cleaning the database, or relocating the show in your file system ... or even changing the file names.  The alternate order stubbornly persist throughout all.

On Windows, at least, one must delete the file with the extension of ".pickle" located in %appdata%\Kodi\cache\scrapers\metadata.tvshows.themoviedb.org.python if they want to successfully import and scrape the series with the original release order again.  Took me a while to hunt the offending file down, to figure out why the setting was so darn persistent.

(I sadly need my Firefly episodes numbered by Release Date order, since the program on which I watch my media —  Infuse for AppleTV —  doesn't recognize DVD order yet).
Reply
#9
(2022-09-06, 17:52)flskydiver Wrote: On Windows, at least, one must delete the file with the extension of ".pickle" located in %appdata%\Kodi\cache\scrapers\metadata.tvshows.themoviedb.org.python
IIRC the cache should only persist for 15 minutes. So if you scrape, realise you made a mistake and change a setting then try to rescrape within that 15 minutes, yes it will reuse the previously scraped data in the existing pickle cache.

Also for other readers, this is how you scrape alternate orders at TMDB... https://kodi.wiki/view/Add-on:TMDb_TV_Sh...ode_Orders
My Signature
Links to : Official:Forum rules (wiki) | Official:Forum rules/Banned add-ons (wiki) | Debug Log (wiki)
Links to : HOW-TO:Create Music Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#10
(2018-12-20, 14:41)scudlee Wrote: The way to get it to work is to make a tvshow.nfo file in the folder of the show, with the contents of the file just being the URL of the episode group you want to use.

I'm confused about that: The "tvshow.nfo" won't have an XML structure, just the URL of the episode group? 

It seems very simple, but it doesn't work with the "Blu-ray Order" of Cowboy Bebop.
Reply
#11
(2023-04-08, 00:09)aviyi Wrote: I'm confused about that: The "tvshow.nfo" won't have an XML structure, just the URL of the episode group? 
Correct. It contains just a single URL. No code, nothing else.
See here... https://kodi.wiki/view/Add-on:TMDb_TV_Sh...ode_Orders

Make sure you are using TMDB TV Shows as the scraper.

(2023-04-08, 00:09)aviyi Wrote: It seems very simple, but it doesn't work with the "Blu-ray Order" of Cowboy Bebop.
Why, what happens? Which show is it as there are three listed. Also provide the URL you are using in the nfo file.

Remember, your episode numbering has to match the episode numbering of the episode group you are trying to scrape.
My Signature
Links to : Official:Forum rules (wiki) | Official:Forum rules/Banned add-ons (wiki) | Debug Log (wiki)
Links to : HOW-TO:Create Music Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#12
(2023-04-08, 00:14)Karellen Wrote: Make sure you are using TMDB TV Shows as the scraper.
(2023-04-08, 00:09)aviyi Wrote: It seems very simple, but it doesn't work with the "Blu-ray Order" of Cowboy Bebop.
I've been using only The Movie Database TV Shows addon for tv show scrapping, so problem with mixing things up.
(2023-04-08, 00:14)Karellen Wrote:
Quote:Why, what happens? Which show is it as there are three listed. Also provide the URL you are using in the nfo file.
I keep getting the Original Air dates for Cowboy Bebop instead of the Blu-ray Order -> Cowboy Bebop (Blu-ray Order)
(2023-04-08, 00:14)Karellen Wrote:
Quote:Remember, your episode numbering has to match the episode numbering of the episode group you are trying to scrape.
All the episodes are named as "Cowboy Bebop S01Eyy Episode Title.mkv" pattern, inside a "Season 1" folder (along with its tvshow.nfo file), inside a "Cowboy Bebop (1998)" folder. Every file and directory has the same user and group owner. No ownership issues here.
Reply
#13
(2023-04-08, 02:17)aviyi Wrote: "Cowboy Bebop S01Eyy Episode Title.mkv" pattern, inside a "Season 1"
Ok. So the episode Asteroid Blues, is that named S01E01 or S01E13?
It should be S01E01

If that is not the issue, then delete the show from your library. Create a Debug Log that captures the scraping of the show. I should be able to see what the problem is.
Just to confirm the tvshow.nfo file is in the TV Show folder, not in the Season folder.
My Signature
Links to : Official:Forum rules (wiki) | Official:Forum rules/Banned add-ons (wiki) | Debug Log (wiki)
Links to : HOW-TO:Create Music Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#14
(2023-04-08, 02:28)Karellen Wrote:
(2023-04-08, 02:17)aviyi Wrote:
Code:
"Cowboy Bebop S01Eyy Episode Title.mkv" pattern, inside a "Season 1"
Ok. So the episode Asteroid Blues, is that named S01E01 or S01E13?
It should be S01E01

If that is not the issue, then delete the show from your library. Create a Debug Log that captures the scraping of the show. I should be able to see what the problem is.
Just to confirm the tvshow.nfo file is in the TV Show folder, not in the Season folder.

Just a note for future reference and anyone who could be trying to do this with no success, and as i'm already here a question too.

I struggled for hours with this same problem and turned out that even if i was removing the show from the library the tmdb tv scraper was using cached data for the show i just removed, even if it successfully detected the tvshow.nfo file with the url of the episode group to use, so nothing seemed to change. it simply worked on its own when i tried it again the next day. so removing the show might not (probably won't) be sufficient as the cached data of the scraper must be flushed anyway.

I actually tried to do that in the first place since i found it was using cached data in the debug logs, but i couldn't find where it was stored so if anyone knows if there is a method to do that from kodi interface would be nice, and if that is not possible, the actual location of the cache for that scraper so at least could be directly deleted in kodi folders. I assume kodi flushes the cache on its own after some time anyway because that just worked for me trying again the next day but a quicker method would be appreciated.
Reply
#15
(2023-06-21, 16:50)seppia Wrote:
(2023-04-08, 02:28)Karellen Wrote:
(2023-04-08, 02:17)aviyi Wrote:
Code:
"Cowboy Bebop S01Eyy Episode Title.mkv" pattern, inside a "Season 1"
Ok. So the episode Asteroid Blues, is that named S01E01 or S01E13?
It should be S01E01

If that is not the issue, then delete the show from your library. Create a Debug Log that captures the scraping of the show. I should be able to see what the problem is.
Just to confirm the tvshow.nfo file is in the TV Show folder, not in the Season folder.

Just a note for future reference and anyone who could be trying to do this with no success, and as i'm already here a question too.

I struggled for hours with this same problem and turned out that even if i was removing the show from the library the tmdb tv scraper was using cached data for the show i just removed, even if it successfully detected the tvshow.nfo file with the url of the episode group to use, so nothing seemed to change. it simply worked on its own when i tried it again the next day. so removing the show might not (probably won't) be sufficient as the cached data of the scraper must be flushed anyway.

I actually tried to do that in the first place since i found it was using cached data in the debug logs, but i couldn't find where it was stored so if anyone knows if there is a method to do that from kodi interface would be nice, and if that is not possible, the actual location of the cache for that scraper so at least could be directly deleted in kodi folders. I assume kodi flushes the cache on its own after some time anyway because that just worked for me trying again the next day but a quicker method would be appreciated.

when using nfo files/local information the content source should be set to 'local information only' which is it's designed function

if you want future scraping you can then change the content back to tmdb and it will update information

the tmdb scraper caches to the kodi temp folder userdata/temp/scrapers
Reply

Logout Mark Read Team Forum Stats Members Help
Alternative sorting of series with tmdb scraper0