Kodi Community Forum

Full Version: <premiered> got wrong date.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I have a lots of movie having this problem. The data in <premiered> tag is wrong. this is one example.

https://pastebin.com/gR5byKgj

i have 10000 movies. How can I fix that with tmm?
what looks the release date from the movies inside tmm like?

just followed the data path across tmm and I do not see any issue there (beside that some source gave tmm the wrong data)
i think i experienced this issue before also

you may have scraped the data for Who Framed Roger Rabbit (1988) from IMDB because the USA 3-D Version release date matches the one in your .nfo

if you rescrape from TMDB you will get <premiered>1988-06-21</premiered> for this movie. It's difficult to say if you rescraped everything from TMDB you will get your desired premiere dates for all your other movies because TMDB also has multiple release dates (regions/versions). You would need to know what data the source pushes and how TMM processes it to get a definitive answer.

it would be nice if the default was theatrical/premiere date for TMDB/IMDB if the API provided such details
Yes. my primary scraper is imdb
if its imdb then you can uncheck Get the release date for chosen country in the scraper settings for movies https://imgur.com/a/sbEkE94 to get <premiered>1988-06-22</premiered> 

this looks like it gets you the premiere date - but @mlaggner should confirm before you run the full rescrape
that could be the issue; I've added a fix in 3.1 to only take the _first_ premiered date for the country (previous it was the last found by mistake) - https://gitlab.com/tinyMediaManager/tiny...7418815b2e
(2020-01-02, 10:52)anbessaw7 Wrote: [ -> ]if its imdb then you can uncheck Get the release date for chosen country in the scraper settings for movies https://imgur.com/a/sbEkE94 to get <premiered>1988-06-22</premiered> 

this looks like it gets you the premiere date - but @mlaggner should confirm before you run the full rescrape
Thanks this works. Unfortunately, i have huge items and rescrapiing would hang my pc.
since i have huge number of items, i need to fix this without tmm. i am using linux and this command will find the .nfo files  including subdirectories, delete line containing <premiered>. Since <premiered> is optional in kodi, this should be no problem. only need to run this once since the issue will no longer happen with newer scrape.
Quote:find . -type f -name '*.nfo' -exec sed -i -e '/<premiered>/d' {} \;
(2020-01-04, 02:57)publicENEMY Wrote: [ -> ]Since <premiered> is optional in kodi,
Not really. Sure you can leave it out, but then you will be unable to sort movies by date, and the date nodes will no longer work.

The easiest solution is to open Kodi's SQL database and run down the column fixing the date. No need to fiddle with nfo files.
(2020-01-04, 03:04)Karellen Wrote: [ -> ]
(2020-01-04, 02:57)publicENEMY Wrote: [ -> ]Since <premiered> is optional in kodi,
Not really. Sure you can leave it out, but then you will be unable to sort movies by date, and the date nodes will no longer work.

The easiest solution is to open Kodi's SQL database and run down the column fixing the date. No need to fiddle with nfo files. 
Hmmm. There are too many dates to fix by hand. Too many movies to fix by tmm. <year> is correct. hopefully kodi will pick that one up. this premiered date issue is really bad. its annoying to see movies 20 years ago as movie premiered this year.
I see from here, emm doesnt support premiered until recently. does this mean that movies scraped with emm cant be sorted by dates?
https://forum.kodi.tv/showthread.php?tid=347187
The <year> tag was depracated a few years ago. It only remains for backwards compatability. There has been no talk of complete removal, but with all the code clean up, it may just happen suddenly.

<premiered> is the correct use for date entries.

(2020-01-04, 03:18)publicENEMY Wrote: [ -> ]does this mean that movies scraped with emm cant be sorted by dates?
If the year is present, it will still sort, but there is no fine sorting. eg if two sequels are released in the same year (matrix), chances are they won't sort correctly (unless alphabetical sorting is on your side). If the proper <premiered> date is used, then proper sorting is possible.
(2020-01-04, 03:04)Karellen Wrote: [ -> ]Not really. Sure you can leave it out, but then you will be unable to sort movies by date, and the date nodes will no longer work.

Could you elaborate more on the functionality that will be gone with lack of <premiered>?
From my understanding
1. when you view your collection, you cant sort the movie by dates
2. you still can see the movie by year(filter)
3. sort by date added still works(recently added)

Can you clarify?
<year>2015</year> provides a year only

<premiered>2015-11-27</premiered> provides a date

Both will allow date sorting in Kodi. Using the <year> is not recommended but will still provide sorting by date in Kodi.

Where the <year> fails is when trying to accurately sort movies in the same year. If you have a group of movies released in 2015, then the sorting in Kodi when using <year> is *Group all movies to year* then *Sort alphabetically*. So your list of movies is simply a-z or z-a for the same year. That's not proper sorting by date.

If you use <premiered> then the addition of the month and day allows for proper sorting by date, rather than just alphabetical. If you happen to then have two movies released on the same day, then it falls back to alphabetical only for those two movies, not the entire list.

Make sense? It depends on how accurate you want to be.
(2020-01-04, 02:52)publicENEMY Wrote: [ -> ]
(2020-01-02, 10:52)anbessaw7 Wrote: [ -> ]if its imdb then you can uncheck Get the release date for chosen country in the scraper settings for movies https://imgur.com/a/sbEkE94 to get <premiered>1988-06-22</premiered> 

this looks like it gets you the premiere date - but @mlaggner should confirm before you run the full rescrape
Thanks this works. Unfortunately, i have huge items and rescrapiing would hang my pc.          
I am assuming you have already considered re-scraping your library in batches that your system can handle and don't want to do this (i.e. change your file structure to reduce the number of movies per source)

another solution you can try is
(1) Export your library to a .csv that contains the movie.title, movie.year, and movie.releaseDate
(2) Sort the difference between the movie.year and movie.release date in ascending order in googlesheets (manageable list for you to review)
(3) Re-scrape the movies manually in TMM 

Image

Here is a simple template you can use to do the above. Just extract it to the folder ..\Tiny Media Manager\templates
-then open tmm, select all your movies, (right-click) Export selected movie(s), select Release Date (list-csv), set an export destination and click export
Pages: 1 2