Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Watched time mismatch #1765

Closed
3 tasks done
pargnyce opened this issue Jan 26, 2024 · 12 comments
Closed
3 tasks done

Watched time mismatch #1765

pargnyce opened this issue Jan 26, 2024 · 12 comments

Comments

@pargnyce
Copy link

pargnyce commented Jan 26, 2024

Confirmation

  • I have read the README.md on the project homepage
  • I have checked if identical issue already exists
  • I have tried downgrading to find version that can be used as a workaround

The problem

The sync command works but the time is mismatched (8 hours difference vs. Plex Media Server Watched time)

Steps to reproduce the behavior

plextraktsync sync

Error trace / logs

No response

Expected behavior

It should sync but time will not match the plex media server

Inspect of problematic items

No response

Workarounds

No response

Install method

pipx

Config file contents

cache:
  path: C:\Users\user\AppData\Local\PlexTraktSync\PlexTraktSync\Cache/trakt_cache
excluded-libraries:
- Private
- Family Holidays
config:
  dotenv_override: true
plex:
  timeout: 30
logging:
  append: true
  console_time: false
  debug: false
  filename: plextraktsync.log
  filter_loggers: null
  filter: null
sync:
  plex_to_trakt:
    collection: false
    clear_collected: false
    ratings: false
    watched_status: true
    watchlist: false
  trakt_to_plex:
    liked_lists: false
    ratings: false
    watched_status: true
    watchlist: false
    watchlist_as_playlist: false
  rating_priority: plex
watch:
  add_collection: false
  remove_collection: false
  scrobble_threshold: 80
  username_filter: true
  media_progressbar: true
xbmc-providers:
  movies: imdb
  shows: tvdb

Version

0.27.5

Python Version

3.10.11

Plex Server Version

1.32.8.7639

Operating System and Version

Windows-10

#1741

@glensc
Copy link
Collaborator

glensc commented Jan 28, 2024

No details. show inspect of the item you have trouble with and what is the data in trakt site? how do you expect anyone to help with so few details? (in fact, no details at all other than your word). and detail of your timezone and your setup. details matter!

@glensc
Copy link
Collaborator

glensc commented Jan 28, 2024

you reported the same in discussions? link the things together! (post the link of each other to the other discussion or issue)

@pargnyce
Copy link
Author

pargnyce commented Jan 29, 2024

Plex Server Logs

Jan 29, 2024 12:04:00.478 [22304] Debug — [Req#c2f] Library item 3437 'Killers of the Flower Moon' got unplayed by account 1!
Jan 29, 2024 12:04:03.671 [23992] Debug — [Req#cee] Library item 3437 'Killers of the Flower Moon' got played by account 1!

Trakt Logs

$ plextraktsync sync
INFO     PlexTraktSync [0.27.5]
INFO     Sync Movie sections: ['Movies @ Home']
INFO     Sync Show sections: ['TV Shows @ Home']
INFO     Marking as watched in Trakt: Killers of the Flower Moon (2023)
Processing Movies @ Home 100% ------------------- 8/8  [ 0:00:01 < 0:00:00 , 226 it/s ]
INFO     Movies @ Home processed in 1.5 seconds
Processing TV Shows @ Home 100% --------------- 13/13  [ 0:00:00 < 0:00:00 , 49 it/s ]
INFO     TV Shows @ Home processed in 0.3 seconds
INFO     Completed full sync in 2.4 seconds

Trakt Website
image

@pargnyce pargnyce reopened this Jan 29, 2024
@glensc
Copy link
Collaborator

glensc commented Jan 30, 2024

still not enough details to go on.

your timezone?

log entries from plextraktsync.log after you've enabled debug. especially the post request of updating play state.

you should probably mark it as unplayed on trakt, and sync with --id option to sync only specific item.

and why ignoring this question?

@pargnyce
Copy link
Author

pargnyce commented Jan 31, 2024

Timezone: GMT+8

plextraktsync.log

@glensc
Copy link
Collaborator

glensc commented Jan 31, 2024

there's no trakt entries in that log! did you really enable debug? you didn't even look the log you posted?

what about inspect of the problematic item?

please do as asked:

  1. enable debug logging
  2. clear the log
  3. run inspect of the problematic item
  4. remove play of the problematic item on trakt
  5. run sync of the problematic item only
  6. run inspect of the problematic item
  7. share the plextraktsync.log

@pargnyce
Copy link
Author

pargnyce commented Jan 31, 2024

I'm sorry if I don't follow. My config sets logging: debug: true. Is that correct?

Here's the log
logs0131.log

And here's the inspect

C:\Users\user>plextraktsync inspect 3437
PlexTraktSync [0.27.5]

Inspecting 3437: <tmdb:466420:Movie:3437:Killers-of-the-Flowe>
Library: Movies @ Home
Plex Web URL:
https://app.plex.tv/desktop/#!/server/f956c2fdc6e30f79a49ba3d9db4dd44f1c4b2172/details?key=/library/metadata/3437
Discover URL:
https://app.plex.tv/desktop/#!/provider/tv.plex.provider.discover/details?key=/library/metadata/5d776d3dad5437001f7d0d5
0
Title: Killers of the Flower Moon
Media.Duration: 03:25:47
Media.Type: 'movie'
Media.Guid: 'plex://movie/5d776d3dad5437001f7d0d50'
Media.Guids: [<Guid:imdb://tt5537002>, <Guid:tmdb://466420>, <Guid:tvdb://135852>]
Audio: '5.1(side)', 'English (DTS-HD MA 5.1)'
Video: 'h264'
Subtitles:
  Subtitle 1: (English) Forced (codec: pgs, selected: True, transient: None)
  Subtitle 2: (English) None (codec: srt, selected: False, transient: None)
  Subtitle 3: (English) SDH (codec: srt, selected: False, transient: None)
  Subtitle 4: (Italiano) None (codec: pgs, selected: False, transient: None)
Parts:
  Part 1: D:\Files\Movies\Killers.of.the.Flower.Moon.2023.mkv
Markers:
Guids:
  Guid: <PlexGuid:tmdb://466420>, Id: 466420, Provider: 'tmdb'
  Guid: <PlexGuid:tvdb://135852>, Id: 135852, Provider: 'tvdb'
  Guid: <PlexGuid:imdb://tt5537002>, Id: tt5537002, Provider: 'imdb'
Metadata: {'collected_at': '2024-01-20:T11:03:30.000Z', 'media_type': 'digital', 'resolution': 'hd_1080p', 'audio':
'dts', 'audio_channels': '5.1'}
Trakt: https://trakt.tv/movies/313884
Plex Rating: None
Trakt Rating: None
Watched on Plex: True
Watched on Trakt: True
Collected on Trakt: False
Plex play history:
- 2024-01-31 10:07:51 <MovieHistory:3437:Killers-of-the-Flowe>: by user on Firefox with Firefox

C:\Users\user>plextraktsync sync
INFO     PlexTraktSync [0.27.5]
INFO     Sync Movie sections: ['Movies @ Home', 'Other Videos @ Home']
INFO     Sync Show sections: ['Anime @ Home', 'KDrama @ Home', 'TV Shows @ Home']
INFO     Marking as watched in Trakt: Killers of the Flower Moon (2023)
Processing Movies @ Home 100% --------------------------------------------------- 8/8  [ 0:00:01 < 0:00:00 , 226 it/s ]
INFO     Movies @ Home processed in 1.6 seconds
Processing Other Videos @ Home   0% ----------------------------------------------- 0/0  [ 0:00:00 < -:--:-- , ? it/s ]
INFO     Other Videos @ Home processed in 0.0 seconds
WARNING  <Show:3623:Attack-on-Titan>: Skipping <PlexGuid:local://3623> because provider local has no external Id
Processing Anime @ Home 100% ------------------------------------------------------ 2/2  [ 0:00:00 < 0:00:00 , ? it/s ]
INFO     Anime @ Home processed in 0.5 seconds
Processing KDrama @ Home 100% ----------------------------------------------------- 2/2  [ 0:00:00 < 0:00:00 , ? it/s ]
INFO     KDrama @ Home processed in 0.1 seconds
Processing TV Shows @ Home 100% ------------------------------------------------ 13/13  [ 0:00:00 < 0:00:00 , 44 it/s ]
INFO     TV Shows @ Home processed in 0.4 seconds
INFO     Completed full sync in 2.6 seconds

C:\Users\user>plextraktsync inspect 3437
PlexTraktSync [0.27.5]

Inspecting 3437: <tmdb:466420:Movie:3437:Killers-of-the-Flowe>
Library: Movies @ Home
Plex Web URL:
https://app.plex.tv/desktop/#!/server/f956c2fdc6e30f79a49ba3d9db4dd44f1c4b2172/details?key=/library/metadata/3437
Discover URL:
https://app.plex.tv/desktop/#!/provider/tv.plex.provider.discover/details?key=/library/metadata/5d776d3dad5437001f7d0d5
0
Title: Killers of the Flower Moon
Media.Duration: 03:25:47
Media.Type: 'movie'
Media.Guid: 'plex://movie/5d776d3dad5437001f7d0d50'
Media.Guids: [<Guid:imdb://tt5537002>, <Guid:tmdb://466420>, <Guid:tvdb://135852>]
Audio: '5.1(side)', 'English (DTS-HD MA 5.1)'
Video: 'h264'
Subtitles:
  Subtitle 1: (English) Forced (codec: pgs, selected: True, transient: None)
  Subtitle 2: (English) None (codec: srt, selected: False, transient: None)
  Subtitle 3: (English) SDH (codec: srt, selected: False, transient: None)
  Subtitle 4: (Italiano) None (codec: pgs, selected: False, transient: None)
Parts:
  Part 1: D:\Files\Movies\Killers.of.the.Flower.Moon.2023.mkv
Markers:
Guids:
  Guid: <PlexGuid:tmdb://466420>, Id: 466420, Provider: 'tmdb'
  Guid: <PlexGuid:tvdb://135852>, Id: 135852, Provider: 'tvdb'
  Guid: <PlexGuid:imdb://tt5537002>, Id: tt5537002, Provider: 'imdb'
Metadata: {'collected_at': '2024-01-20:T11:03:30.000Z', 'media_type': 'digital', 'resolution': 'hd_1080p', 'audio':
'dts', 'audio_channels': '5.1'}
Trakt: https://trakt.tv/movies/313884
Plex Rating: None
Trakt Rating: None
Watched on Plex: True
Watched on Trakt: True
Collected on Trakt: False
Plex play history:
- 2024-01-31 10:07:51 <MovieHistory:3437:Killers-of-the-Flowe>: by user on Firefox with Firefox

@glensc
Copy link
Collaborator

glensc commented Jan 31, 2024

you should edit your post and remove mistakes. not interested output of commands that don't exist. if you have problem with that send a pr updating documentation. as for the usage every command has --help flag: plextraktsync sync --help

also, terminal output can be put into code fence markup to make them readable:

@glensc
Copy link
Collaborator

glensc commented Jan 31, 2024

seems the log doesn't contain info what payload was posted for sync history

2024-01-31 18:11:07,769 DEBUG[requests_cache.session]:Skipping cache write for URL: https://api-v2launch.trakt.tv/sync/history
2024-01-31 18:11:07,769 DEBUG[trakt.core]:RESPONSE [post] (https://api-v2launch.trakt.tv/sync/history): <Response [201]>
2024-01-31 18:11:07,769 DEBUG[PlexTraktSync.TraktMarkWatchedWorker]:Submitted add_to_history: {'added': {'movies': 1}}

but since the timestamp issue probably global, is the collected date accurate? you can see plextraktsync side value in the inspect command:

Metadata: {'collected_at': ...

@glensc
Copy link
Collaborator

glensc commented Jan 31, 2024

seems already your PMS log and plextraktsync play history tiestamps don't match

plextraktsync:

2024-01-31 10:07:51 MovieHistory:3437:Killers-of-the-Flowe: by user on Firefox with Firefox

PMS:

Jan 29, 2024 12:04:00.478 [22304] Debug — [Req#c2f] Library item 3437 'Killers of the Flower Moon' got unplayed by account 1!
Jan 29, 2024 12:04:03.671 [23992] Debug — [Req#cee] Library item 3437 'Killers of the Flower Moon' got played by account 1!

@glensc
Copy link
Collaborator

glensc commented Jan 31, 2024

You can also use this pr so the data sent to trakt is logged:

@glensc
Copy link
Collaborator

glensc commented Mar 7, 2024

closing. user has dissapeared

@glensc glensc closed this as completed Mar 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants