Hide watched option not working when using MySQL database
#1
I have two A905X(S905X) units running the Coreelec 8.95.7 release (Kodi v18 Leia (Release Candidate 4).
I added MySQL to my Ubuntu Samba server so that I could have a synced media experience with both units.The server setup seemed to go fine. I created/edited the advancedsettings.xml per the Kodi wiki.
The units came up with a blank library as expected.
I added my samba share sources for my TV and Movies. The scan seemed to work fine. Paused videos showed the same pause point regardless of the playback device.

Now the issue:
I used the WatchedList add-on to restore the watched/unwatched state as I during other kodi migrations I have had in the past.
All the movies seem to behave as expected.
The TV shows on the other hand are misbehaving.
On an initial boot when I go into the tv shows with Hide watched enabled. No shows marked watched are visible as expected.
If I then select a show to view the eps or seasons, and return to the show listings I can see the shows marked as watched and unwatched. The check mark is shown on the watched shows. The Hide watched option is still enabled, but not working.
If I return to the Movies, all behavior is as expected in the Movies.

Here is a pic of what I am seeing on the TV.
Image

I have tried deleting the database from MySQL and recreating the whole thing in case it was corrupted somehow. The end results were the same.
I also see this behavior when use Confluence or Estuary skin, so I do not think it is skin related.

This is my first attempt at creating a MySQL database for Kodi, so I am guessing I have a permission wrong or something somewhere. However I have no idea where to start looking.
Does anyone have a suggestion on how I might fix this strange behavior?
Thanks.
Reply
#2
Update:
I discovered that the movies are also misbehaving. After one movie is started all the watched movies appear in the list despite the Hide watched option being toggled on.
Reply
#3
Please reproduce with vanilla kodi on a supported platform.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#4
Things work fine here with either MySQL or MariaDB databases with Kodi rc5.2, including watched statuses.

Perhaps you should contact the CoreELEC forum if there is erratic behavior on your devices.
Got a Kodi problem? Provide a full Debug log (wiki) | Usefull pages: First time user (wiki) | Troubleshooting (wiki) | Free content (wiki) | Forum rules (wiki) | VPN policy (wiki)
Reply
#5
I am having the same issue, and have been having this issue now for months.  (and updated kodi a few times without resolution)

My file store and database are both stored on a Synology NAS, which I have several TVs hitting using FireTV sticks, along with my computer (win10).  I am using MariaDB on the Synology, and have my 'advancedsettings.xml' pointing to it:
Quote:    <videodatabase>
        <type>mysql</type>
        <host>xxx.xxx.x.xx</host>
        <port>xxxx</port>
        <user>xxxxx</user>
        <pass>xxxxxxx</pass>
    </videodatabase>
This had worked great for a long time, until this watched / unwatched thing started.

When I first pull up Kodi, with my filters set to only show unwatched, everything works as expected.  When I then watch an episode or movie, it get's flagged as watched, but the filters then fail to work.  The result is that even though the filters specify 'Unwatched' I see everything.  In the case of series, for instance, I see "12 / 12" with 'Unwatched' still selected under Filter.  Then the weird thing, if I click it to "Watched" the list goes blank and it show "0".  Setting to "All videos" works fine, but going back to 'Unwatched' still shows everything.

Work-around is to select a show lie "12 / 12"  (all watched) and select "Mark As Watched" ...  then all the other shows that were fully watched drop off, and the 'Unwatched' works as expected once again.

This behavior is the same, on both the FireTV and the PC.  I currently validated this on my PC, with nothing else running.  My PC has a few add-ons install, but nothing having to do with watched or unwatched stuff.

I am pretty sure that this all started somewhere in the 17.x versions.  I was really hoping the 18.x versions would fix it, but I am on 18.2 and it persists.
Reply
#6
(2019-01-26, 19:44)fritsch Wrote: Please reproduce with vanilla kodi on a supported platform.

I obtained a computer, installed Ubuntu 18.04, installed Kodi 18.02, and am able to reproduce the same issue.
Reply
#7
(2019-01-26, 19:21)wizardknight Wrote: This is my first attempt at creating a MySQL database for Kodi, so I am guessing I have a permission wrong or something somewhere. However I have no idea where to start looking.
My first troubleshooting step would be to use the DB credentials to tap into the database and see what records I can view (and possibly change), just to check there's nothing preventing accessibility server-end.  Are you able to do that from the different client devices?
Reply
#8
(2019-05-18, 21:56)Preacher Wrote:
(2019-01-26, 19:21)wizardknight Wrote: This is my first attempt at creating a MySQL database for Kodi, so I am guessing I have a permission wrong or something somewhere. However I have no idea where to start looking.
My first troubleshooting step would be to use the DB credentials to tap into the database and see what records I can view (and possibly change), just to check there's nothing preventing accessibility server-end.  Are you able to do that from the different client devices? 
I don't think it is a credentials issue as the gui displays the correct watched state during the very first load of the movies.
I can see it connecting to the sql server in the logs too. No errors there
2019-05-18 23:39:20.305 T:3987919728  NOTICE: MYSQL: Connected to version 10.3.14-MariaDB
2019-05-18 23:39:20.367 T:3987919728  NOTICE: Running database version MyMusic72
2019-05-18 23:39:20.435 T:3987919728  NOTICE: Running database version MyVideos116
2019-05-18 23:39:20.442 T:3987919728  NOTICE: Running database version TV32
2019-05-18 23:39:20.448 T:3987919728  NOTICE: Running database version Epg12


I actual just rebuilt the entire database this evening, and I can consistently reproduce the issue.
My current build has two kodi units. One of the units now houses the Mysql database. There other accesses the database over the network.
On the units housing the mysql server (I am now using kodi mariadb plugin rather than a separate dedicated Mysql system -which also shows the same issue on all remote units) I am not seeing any issues.
On the remote unit I can produce the issue 95% of the time with these steps.
1. Fresh boot.
2. Click on Movies - I will see only unwatched movies at this point. 444 unwatched at the moment.
3. Return to home.
4. Click on Movies a second time. - At this point all movies are shown

I can return to home and back into movies as many times as I want, and all movies are shown regardless of their watched status.
If I go into Movies -> Home -> TVShows  -> Home -> Movies, it will reset the Movies and show only the unwatched until I go to home, and then back to movies.

It is almost like the initial load provides for extra time to load the data from MySql, and the reload does not. Then it partially times out after the first try.
I do get the full move listing every time, and I get the correct watched status on the first load, so I don't think it is a permissions issue on the sql server side.
I think the wireless network should be sufficient. It is wireless N at the slowest point, and is able to playback streaming media from the NAS without any issues.

Here is a fresh log (hopefully) showing the issue when I access movies.
http://ix.io/1JqT from the corelelec addon
And from temp/kodi.log around time stamp 23:40:04.834 at https://paste.kodi.tv/lolejacoza.kodi

The issue exists with all of the skins I have tried, so I don't think that is the issue either.
Reply
#9
Enable the "Database component" in Kodi's debugging section for more detailed SQL query logging.
Restart Kodi, and reproduce the problem(s).

Also installing and testing the other MariaDB latest releases of the 10.1 & 10.2 branches could be interesting.
Got a Kodi problem? Provide a full Debug log (wiki) | Usefull pages: First time user (wiki) | Troubleshooting (wiki) | Free content (wiki) | Forum rules (wiki) | VPN policy (wiki)
Reply
#10
(2019-05-19, 10:35)Klojum Wrote: Enable the "Database component" in Kodi's debugging section for more detailed SQL query logging.
Restart Kodi, and reproduce the problem(s).

Also installing and testing the other MariaDB latest releases of the 10.1 & 10.2 branches could be interesting.
I 10.2 causes the same issues. I never rolled back all the way to 10.1.
Standard mysql also caused the same issues when I tried it months ago. I switched to MariaDB in the hopes that it would be more efficient and resolve the issue.

Here is the requested log.
Order of events in the log after reboot:
1. Clicked on Movies. Shows normally/ watched movies hidden
2. Home
3. Clicked on Movies. Shows all movies
4. Home
5. TV Shows
6. Movies. Shows normally.
7. Home
8. Clicked on Movies. Shows all movies again.

https://paste.kodi.tv/okotihamec.kodi
Reply
#11
(2019-05-19, 10:35)Klojum Wrote: Enable the "Database component" in Kodi's debugging section for more detailed SQL query logging.
Restart Kodi, and reproduce the problem(s).

Also installing and testing the other MariaDB latest releases of the 10.1 & 10.2 branches could be interesting.

Did you see anything odd in the logs I posted?
Reply
#12
I tried moving the sql server to a more powerful PC, and there was no difference.
That is not surprising as the old one was not maxing out the cpu, mem, or network.

I saw one response to the thread stating they were able to reproduce the issue. Can anyone else confirm they are seeing this behavior?
Any other thoughts of something I could try?
Reply
#13
Bump.
Reply
#14
I'm getting the same symptoms - I'll update my library and it will look like it's filtered correctly. But if I watch a show or exit out of "TV Shows" and go back in, it'll show everything that is watched and unwatched. When I check the filter, it still shows as "Unwatched". This has been happening since release of v18 and was hoping it would've been a fix by now. 

I'm running on a Rasp Pi 3 using LibreELEC v9.0.2(Kodi 18.2) - my library is maintained by sql database on a Synology NAS

Appreciate if any can help shed some light on how to fix this or if it can be fixed next release.

Thanks!
Reply
#15
@Klojum
@fritsch 
We have three users now reporting being able to reproduce this odd behavior.
Is there anything we can do to help resolve it?
Reply



Logout Mark Read Team Forum Stats Members Help
Hide watched option not working when using MySQL database0
This forum uses Lukasz Tkacz MyBB addons.