Release WatchedList - service to automatically save/restore watched state
(2019-04-17, 21:40)HeresJohnny Wrote: I would like to add some observations related to the imdb ID.
[...] Unfortunately, the default scrapers in Kodi for movies and tv shows are now set to TMDB. As I already commented in the TMDB scraper thread, items which are scraped with that scraper have existing IMDB nos. forcibly removed and only the TMDB no. is added/kept in the db. The Universal Movie scraper on the other hand doesn't add the TMDB ID.
Karellen Wrote: "TheMovieDB-TVShows" replaced "TheTVDB" as the default scraper during Nov 2018. If you originally scraped with TVDB and are now rebuilding your library with NFO Files, ensure the correct scraper is active.

This messed up the situation a little for my video library (mySQL):
SELECT tvshow.idShow,tvshow.c12, uniqueid.type, uniqueid.value, tvshow.c00 FROM tvshow INNER JOIN uniqueid ON tvshow.c12 = uniqueid.uniqueid_id;
Fields: internal number of tv show, reference to uniqueid, type of id, id of the provider, title
169 22829 tmdb 60741 Ascension
170 22896 unknown 247897 Homeland
171 23551 unknown 121361 Game of Thrones
172 23588 tvdb 71663 Die Simpsons
I had a deeper look into the tvdb vs tmdb issue and it seems to have bigger implications on the WatchedList addon than I thought.
There is a table `uniqueid` that stores the id of the databases TheTVDB (tvdb) and TheMovieDB (tmdb) in the Kodi Video Library:
http://localhost:8080/jsonrpc?request={"jsonrpc": "2.0", "method": "VideoLibrary.GetTVShows", "params": {"properties": ["title", "imdbnumber", "uniqueid"], "sort": { "order": "ascending", "method": "title" } }, "id": 1}
The key `idShow` in the tvshows table of the WatchedList database was only referring to the field `imdbnumber` of the JSON output, which from retroperspective is not a good choice for a unique identifier of watched status. It might be that I started with API version 4 instead of version 6, where the field uniqueid was introduced.

So the situation for me and the average user of this addon is that we have lots of entries in the database referring to the tvdb IDs which were scraped and watched over the last years. For new media (scraped differently) this data can not be used and duplicate entries are created. E.g. in my WatchedList database I now have "The Last Kingdom" as "63333" (tmdb) and "298566" (tvdb); at least with identical playcount data.
(2019-04-18, 06:36)schapplm Wrote: As for the tv shows I also support this to be done on scraper/database/json-API-level.
I have to think about a solution how to fix it at the end of this addon, since the data is now duplicate and old data can not be used. Creating an automatic upgrade mechanism of the table will take time, however.
My addon: service.watchedlist
My HTPC: Kodi 18.3; Ubuntu 16.04 LTS x64; AMD A6-6400K; MSI FM2-A55M-E33; 4GB Kingston HyperX RAM; Streacom FC8B Evo with 120W picoPSU
Thread Rating:
  • 3 Vote(s) - 5 Average

Messages In This Thread
RE: WatchedList - service to automatically save/restore watched state - by schapplm - 2019-08-24, 17:47

Logout Mark Read Team Forum Stats Members Help
WatchedList - service to automatically save/restore watched state53