•   
  • 1
  • 128
  • 129
  • 130(current)
  • 131
  • 132
  • 179
  •   
[RELEASE] Texture Cache Maintenance utility
To remove a movie from the library:
Code:
texturecache.py remove movie #
where # is the movie id (in your case either 23 or 126).

Rather than search using SQL, you can "dump" all movies (as "file" isn't a filter field)
Code:
texturecache.py jd movies >/tmp/movies.dat
then search for instances of "El último hombre... viv".

Alternatively, if both movies have the same imdbnumber, the following should list them both:
Code:
texturecache.py duplicates
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
(2016-04-11, 01:03)Milhouse Wrote: To remove a movie from the library:
Code:
texturecache.py remove movie #
where # is the movie id (in your case either 23 or 126).

Rather than search using SQL, you can "dump" all movies (as "file" isn't a filter field)
Code:
texturecache.py jd movies >/tmp/movies.dat
then search for instances of "El último hombre... viv".

I'm thinking about doing this automatically. Is there a "parsed date field", than contains when the nfo was read, somewhere in the database? I will happily delete the oldest entry when two movies share the same file.

(2016-04-11, 01:03)Milhouse Wrote: Alternatively, if both movies have the same imdbnumber, the following should list them both:
Code:
texturecache.py duplicates

Not this time Sad, the two entries have different imdbnumber.

Thanks for all the info!
Reply
(2016-04-11, 07:37)ifsnop Wrote: I'm thinking about doing this automatically. Is there a "parsed date field", than contains when the nfo was read, somewhere in the database?

No, unless you change the default dateadded to the time when the file is scraped - the default is normally the modification timestamp of the media file.

However the problem you had with Kolchak is entirely because Media Companion created the NFO using completely the wrong movie file (which then meant "texturecache.py qa" couldn't find the Kolchak NFO file even after it had been corrected, as the NFO file name is based on the movie file name). I can't imagine this happening very often, but if it does you need to look at how Media Companion is working.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
(2016-04-11, 12:28)Milhouse Wrote:
(2016-04-11, 07:37)ifsnop Wrote: I'm thinking about doing this automatically. Is there a "parsed date field", than contains when the nfo was read, somewhere in the database?

No, unless you change the default dateadded to the time when the file is scraped - the default is normally the modification timestamp of the media file.

If it means modifying a python script, I will give it a try. It makes more sense to me, storing the NFO file instead of the mkv file. If Kodi parses NFO files, it should be aware if someone modifies it.

(2016-04-11, 12:28)Milhouse Wrote: However the problem you had with Kolchak is entirely because Media Companion created the NFO using completely the wrong movie file (which then meant "texturecache.py qa" couldn't find the Kolchak NFO file even after it had been corrected, as the NFO file name is based on the movie file name). I can't imagine this happening very often, but if it does you need to look at how Media Companion is working.

MC mistakenly scrapped the wrong movie title. Everytime a scrapper fails to recognize the movie title, and then the user corrects it, Kodi will duplicate the entry in the database. I wonder why nobody else is having the same problem. Do you think how this problem could be fixed? I don't mind coding a solution and making a PR to your script Smile
Reply
(2016-04-11, 20:17)ifsnop Wrote: If it means modifying a python script, I will give it a try. It makes more sense to me, storing the NFO file instead of the mkv file. If Kodi parses NFO files, it should be aware if someone modifies it.

No, it means adding a setting to advancedsettings.xml and re-scraping your library.

http://kodi.wiki/view/Advancedsettings.xml#videolibrary - see <dateadded>.

(2016-04-11, 20:17)ifsnop Wrote: MC mistakenly scrapped the wrong movie title. Everytime a scrapper fails to recognize the movie title, and then the user corrects it, Kodi will duplicate the entry in the database. I wonder why nobody else is having the same problem. Do you think how this problem could be fixed? I don't mind coding a solution and making a PR to your script Smile

You could dump the movie data ("jd movies") and parse it to spot an anomaly (two movies/same file, perhaps?) then remove one of them (the movie without an NFO?), but this isn't likely to be a common requirement and not something I'm likely to add. It should be possible to script such a solution using various calls to texturecache.py - see the first post for details, or "texturecache.py help" on what calls are available - you can use "texturecache.py directory" for example to obtain a directory listing and determine if the NFO exists.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
Did you run full mediacompanion or mc-com -m?

Full mediacompanion means you can check, confirm the correct movie was scraped. Change it if not.

I would be interest in getting the filename so get can test and possibly reduce the chance of returning the incorrect movie.
Reply
(2016-04-11, 21:29)vbat99 Wrote: Did you run full mediacompanion or mc-com -m?

Full mediacompanion means you can check, confirm the correct movie was scraped. Change it if not.

I would be interest in getting the filename so get can test and possibly reduce the chance of returning the incorrect movie.

Hi vbat99,

I ran full media companion. If better, we could move this discussion to the MC forums, but long story short, MC messes when the name has UTF-8 characters like accented vowels.

mc accented search - snapshot

Code:
El último hombre... vivo (1971) Charlton Heston, Anthony Zerbe, Rosalind Cash, Paul Koslo, Lincoln Kilpatrick.dual.subs.mkv
Reply
(2016-04-11, 22:38)ifsnop Wrote:
(2016-04-11, 21:29)vbat99 Wrote: Did you run full mediacompanion or mc-com -m?

Full mediacompanion means you can check, confirm the correct movie was scraped. Change it if not.

I would be interest in getting the filename so get can test and possibly reduce the chance of returning the incorrect movie.

Hi vbat99,

I ran full media companion. If better, we could move this discussion to the MC forums, but long story short, MC messes when the name has UTF-8 characters like accented vowels.

mc accented search - snapshot

Code:
El último hombre... vivo (1971) Charlton Heston, Anthony Zerbe, Rosalind Cash, Paul Koslo, Lincoln Kilpatrick.dual.subs.mkv

We'll take this to the MC Thread. 2308555 (post)
Reply
hello,
my objective is to update the artwork on a regular basis to always get the latest and highest rated artwork.
I tried:
Code:
texturecache.py C tvshows @cache.refresh='2010-12-31 23:59:59'  @allow.recacheall=yes @section=salon
and I noticed that it worked for some shows but for other shows, it was caching an artwork which didn't have the highest rating.
After investigation, I noticed that whenever it didn't work, the artwork cached by texturecache.py had a 0 rating on thetvdb (and it seems that when it worked, there was no unrated artwork for the corresponding show)
examples: it cached poster http://thetvdb.com/banners/posters/282670-12.jpg for Narcos (rated 0 with 0 votes) while it cached poster http://thetvdb.com/banners/posters/262407-6.jpg for Black Sails (rated 7.1 and no unrated poster for Black Sails)
I tried to put a note on the artwork and launch the script again, but there is no change in the artwork which is re-cached

1. Is there anything wrong in what I'm doing?
2. If the answer to 1. is no, then I assume there might be an issue with the selection of the artwork to be cached in the script when there is no rating
Reply
The script isn't a scraper, it only caches whatever artwork has been scraped by your scraper. If the "wrong" artwork is being cached it's because your scraper has scraped the wrong artwork. Caching is not scraping.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
Does this makes any sense? Of course, the nfo file exists.

After doing:

Code:
# texturecache.py qax tvshows @qaperiod=9999 @qa.nfo.refresh=0

I alway get this warning:

Code:
Episode  [House, Temporada 6 Episode 6x01                   ]: WARN (missing nfo)
Episode  [House, Temporada 6 Episode 6x02                   ]: WARN (missing nfo)
Episode  [House, Temporada 6 Episode 6x03                   ]: WARN (missing nfo)
...

How can I solve this? The other seasons are parsed without problems.
Reply
Run:
Code:
texturecache.py qax tvshows House @qaperiod=9999 @qa.nfo.refresh=0 @logfile=/tmp/tc.log
then upload /tmp/tc.log somewhere (zip it if required), and paste a link.

Also, upload the directory listing for House Season 6 (screenshot, or "ls -l"), so that I can see how the files are named.

There's probably a mismatch occurring somewhere.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
Find it here,

https://gist.github.com/ifsnop/69dec75d5...f6d5762e95


Thxs in advance.
Reply
(2016-05-22, 01:00)ifsnop Wrote: Find it here,

https://gist.github.com/ifsnop/69dec75d5...f6d5762e95


Thxs in advance.

The first episode of House Season 6 is a two-part episode, and you've named these files:
Code:
-rw-rw-r--  1 1000 100 2,1G may 17 09:29 6x01.1 Roto. Parte 1 (Broken. Part 1).mkv
-rw-rw-r--  1 1000 100 2,7K may 17 09:29 6x01.1 Roto. Parte 1 (Broken. Part 1).nfo
-rw-rw-r--  1 1000 100  24K may 17 09:29 6x01.1 Roto. Parte 1 (Broken. Part 1)-thumb.jpg
-rw-rw-r--  1 1000 100 2,1G may 17 09:29 6x01.2 Roto. Parte 2 (Broken. Part 2).mkv
-rw-rw-r--  1 1000 100 2,7K may 17 09:29 6x01.2 Roto. Parte 2 (Broken. Part 2).nfo
-rw-rw-r--  1 1000 100  24K may 17 09:29 6x01.2 Roto. Parte 2 (Broken. Part 2)-thumb.jpg
-rw-rw-r--  1 1000 100 2,1G may 17 09:29 6x02 Fracaso rotundo (Epic Fail).mkv
-rw-rw-r--  1 1000 100 2,5K may 17 09:29 6x02 Fracaso rotundo (Epic Fail).nfo
-rw-rw-r--  1 1000 100  19K may 17 09:29 6x02 Fracaso rotundo (Epic Fail)-thumb.jpg
-rw-rw-r--  1 1000 100 2,1G may 17 09:29 6x03 El tirano (The Tyrant).mkv
-rw-rw-r--  1 1000 100 2,7K may 17 09:29 6x03 El tirano (The Tyrant).nfo
-rw-rw-r--  1 1000 100  47K may 17 09:29 6x03 El tirano (The Tyrant)-thumb.jpg
[/code]

According to your media library, the first three episodes in Season 6 are:
Code:
"episodeid":2591,
"file":"nfs://192.168.0.200/mnt/hdseries/1/series_1/House/s06/6x01 Roto. Parte 1 (Broken. Part 1).mkv",
"label":"6x01. Roto",

"episodeid":2592,
"file":"nfs://192.168.0.200/mnt/hdseries/1/series_1/House/s06/6x02 Roto. Parte 2 (Broken. Part 2).mkv",
"label":"6x02. Fracaso rotundo",

"episodeid":2593,
"file":"nfs://192.168.0.200/mnt/hdseries/1/series_1/House/s06/6x03 Fracaso rotundo (Epic Fail).mkv",
"label":"6x03. El Tirano",

Which is not right at all - I'd be very surprised if Kodi is able to play any of the files in Season 6, as the media files Kodi has scraped don't exist.

The reason you've got this issue is because you've named the multi-part files incorrectly, meaning Kodi hasn't seen the two files of the first episode as a multi-part file. Consequently it's used the second file in your multi-part as the media file for episode 2 (6x02), and the media file for episode 2 has been used to create episode 3 (6x03). And so on.

What is a little odd is that the file names Kodi is using are also incorrect, have you renamed these files after they were scraped?

My advice would be to rename the six 6x01 media files using the correct multi-part naming format (whatever that might be, see the wiki: http://kodi.wiki/view/File_stacking#Spli...tacking.29) then remove the files (all of season 6, and any other seasons with similar issues) then rescrape your library - Kodi should scrape both 6x01 parts as a single "stacked" file/episode.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
(2016-05-22, 04:33)Milhouse Wrote:
Code:
-rw-rw-r--  1 1000 100 2,1G may 17 09:29 6x01.1 Roto. Parte 1 (Broken. Part 1).mkv
-rw-rw-r--  1 1000 100 2,7K may 17 09:29 6x01.1 Roto. Parte 1 (Broken. Part 1).nfo
-rw-rw-r--  1 1000 100  24K may 17 09:29 6x01.1 Roto. Parte 1 (Broken. Part 1)-thumb.jpg

According to your media library, the first three episodes in Season 6 are:
Code:
"episodeid":2591,
"file":"nfs://192.168.0.200/mnt/hdseries/1/series_1/House/s06/6x01 Roto. Parte 1 (Broken. Part 1).mkv",
"label":"6x01. Roto",

Which is not right at all - I'd be very surprised if Kodi is able to play any of the files in Season 6, as the media files Kodi has scraped don't exist.

This is another case when I rename a file and Kodi doesn't notice (it doesn't notice the new file, neither the old and missing one), because it was renamed after scrapping.

Quote:The reason you've got this issue is because you've named the multi-part files incorrectly, meaning Kodi hasn't seen the two files of the first episode as a multi-part file. Consequently it's used the second file in your multi-part as the media file for episode 2 (6x02), and the media file for episode 2 has been used to create episode 3 (6x03). And so on.

What is a little odd is that the file names Kodi is using are also incorrect, have you renamed these files after they were scraped?

My advice would be to rename the six 6x01 media files using the correct multi-part naming format (whatever that might be, see the wiki: http://kodi.wiki/view/File_stacking#Spli...tacking.29) then remove the files (all of season 6, and any other seasons with similar issues) then rescrape your library - Kodi should scrape both 6x01 parts as a single "stacked" file/episode.

Your link pointed to how a movie should be named, and this is a tvshow. I think the naming is correct for tvshows stacking.

Since obvioulsy Kodi db has run out of sync with fs, can I trigger a database resync/update from texturecache? (a part from setting contents to none from inside Kodi and then again to tvshows).
Reply
  •   
  • 1
  • 128
  • 129
  • 130(current)
  • 131
  • 132
  • 179
  •   
 
Thread Rating:
  • 17 Vote(s) - 4.76 Average



Logout Mark Read Team Forum Stats Members Help
[RELEASE] Texture Cache Maintenance utility4.7617