yuliskov / SmartTube

SmartTube - an advanced player for set-top boxes and tvs running Android OS
https://www.patreon.com/smarttube
Other
19.04k stars 1.06k forks source link

STN watch history unaccounted in the YT "Time watched" stats. #899

Open bartoszek opened 3 years ago

bartoszek commented 3 years ago

Just notice there's a discrepancy with the playback history pushed by STN to YT. YT history seems fine: watched videos are recorded alongside partial progress indicator. But in contrary to Vanced or the original YT app: STN renders "Timed watched" statistic blank.

5917746437855230020_121

5917746437855230018_121

Mathsvlog commented 2 years ago

I noticed this too after I recently decided to start limiting my daily time on YT.

Thought maybe some setting was preventing it from working. Tried playing with different video codec presets, all developer options enabled, SponsorBlock disabled. Nothing worked so far.

Verified that Time Watched tracking does still work on SmartYouTubeTV but not SmartTubeNext.

Mathsvlog commented 2 years ago

Just a guess, but searching the SmartTubeLegacy code, I found this call to the Youtube API stats/watchtime. https://github.com/yuliskov/SmartTubeLegacy/blob/48132697efdef50f474c34104255d2285bf43dbb/smartyoutubetv/src/main/java/com/liskovsoft/smartyoutubetv/misc/youtubeutils/YouTubeTracker.java#L28

I don't know if this is actually what affects the Time Watched value that appears in the YT app, but this call does seem to be missing from the SmartTubeNext code. https://github.com/yuliskov/SmartTubeNext/search?q=watchtime

Mathsvlog commented 2 years ago

Actually, legacy class YouTubeTracker doesn't seem to be directly used in code. YouTubeHistoryUpdater seems more relevant.