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

Sync library to trakt.tv failed #45

Closed
MateEke opened this issue May 28, 2020 · 10 comments
Closed

Sync library to trakt.tv failed #45

MateEke opened this issue May 28, 2020 · 10 comments
Labels
bug This PR or Issue describes or fixes something that isn't working

Comments

@MateEke
Copy link

MateEke commented May 28, 2020

Server:
Version: 10.5.5
Operating System: Linux
Architecture: X64

Plugin: 9.0.0.0

Log:

The UTC time represented when the offset is applied must be between year 0 and 10,000. (Parameter 'offset') at System.DateTimeOffset.ValidateDate(DateTime dateTime, TimeSpan offset) at System.DateTimeOffset..ctor(DateTime dateTime) at System.DateTimeOffset.op_Implicit(DateTime dateTime) at Trakt.Api.TraktApi.SetRequestHeaders(HttpRequestOptions options, TraktUser traktUser) at Trakt.Api.TraktApi.GetFromTrakt(String url, CancellationToken cancellationToken, TraktUser traktUser) at Trakt.Api.TraktApi.SendGetAllWatchedMoviesRequest(TraktUser traktUser) at Trakt.ScheduledTasks.SyncLibraryTask.SyncMovies(User user, TraktUser traktUser, ISplittableProgress`1 progress, CancellationToken cancellationToken) at Trakt.ScheduledTasks.SyncLibraryTask.SyncUserLibrary(User user, TraktUser traktUser, ISplittableProgress`1 progress, CancellationToken cancellationToken) at Trakt.ScheduledTasks.SyncLibraryTask.Execute(CancellationToken cancellationToken, IProgress`1 progress) at Emby.Server.Implementations.ScheduledTasks.ScheduledTaskWorker.ExecuteInternal(TaskOptions options)
@Zusier
Copy link

Zusier commented Jun 25, 2020

I have the EXACT issue on windows. Have force re-authorized multiple times so I dont think thats the issue

@Zusier
Copy link

Zusier commented Jun 26, 2020

Welp, after running into a completely different issue with my library it works now :p

@oddstr13 oddstr13 added the question This Issue contains a question label Aug 19, 2020
@oddstr13
Copy link
Member

Is this issue still present in Jellyfin 10.6.3 with plugin version 9?

What is your system timezone?

@int3ro
Copy link

int3ro commented Nov 6, 2020

I have the same issue:

[2020-11-06 00:10:33.474 +01:00] [INF] [32] Emby.Server.Implementations.ScheduledTasks.TaskManager: "IntervalTrigger" fired for task: "Sync library to trakt.tv"
[2020-11-06 00:10:33.475 +01:00] [INF] [32] Emby.Server.Implementations.ScheduledTasks.TaskManager: Queueing task "SyncLibraryTask"
[2020-11-06 00:10:33.476 +01:00] [INF] [4] Emby.Server.Implementations.ScheduledTasks.TaskManager: Executing "Sync library to trakt.tv"
[2020-11-06 00:10:33.518 +01:00] [ERR] [4] Emby.Server.Implementations.ScheduledTasks.TaskManager: Error
System.ArgumentOutOfRangeException: The UTC time represented when the offset is applied must be between year 0 and 10,000. (Parameter 'offset')
   at System.DateTimeOffset.ValidateDate(DateTime dateTime, TimeSpan offset)
   at System.DateTimeOffset..ctor(DateTime dateTime)
   at System.DateTimeOffset.op_Implicit(DateTime dateTime)
   at Trakt.Api.TraktApi.SetRequestHeaders(HttpRequestOptions options, TraktUser traktUser)
   at Trakt.Api.TraktApi.GetFromTrakt(String url, CancellationToken cancellationToken, TraktUser traktUser)
   at Trakt.Api.TraktApi.SendGetAllWatchedMoviesRequest(TraktUser traktUser)
   at Trakt.ScheduledTasks.SyncLibraryTask.SyncMovies(User user, TraktUser traktUser, ISplittableProgress`1 progress, CancellationToken cancellationToken)
   at Trakt.ScheduledTasks.SyncLibraryTask.SyncUserLibrary(User user, TraktUser traktUser, ISplittableProgress`1 progress, CancellationToken cancellationToken)
   at Trakt.ScheduledTasks.SyncLibraryTask.Execute(CancellationToken cancellationToken, IProgress`1 progress)
   at Emby.Server.Implementations.ScheduledTasks.ScheduledTaskWorker.ExecuteInternal(TaskOptions options)
[2020-11-06 00:10:33.554 +01:00] [INF] [4] Emby.Server.Implementations.ScheduledTasks.TaskManager: "Sync library to trakt.tv" Failed after 0 minute(s) and 0 seconds

Version: 10.6.4
Operating System: Linux
Architecture: X64
Plugin Version: 10.0.0.0

@oddstr13 oddstr13 added bug This PR or Issue describes or fixes something that isn't working and removed question This Issue contains a question labels Dec 12, 2020
@jcaldeira
Copy link

jcaldeira commented Dec 12, 2020

Version: 10.6.4
Operating System: Windows
Architecture: X64
Plugin Version: 10.0.0.0

I don't think my type of logs error are the same, but I do have the same problem: "Sync library to trakt.tv failed"
I'll leave a link to my logs from log file and from alert notification I did pick some log lines out that were in the middle of it this error in particular. I hope all information is in there.

@Shadowghost
Copy link
Contributor

Shadowghost commented Apr 21, 2022

Anyone still experiencing this with the current plugin?

@crobibero
Copy link
Member

Initial guess is that we need to guard for items with a parameter of DateTime.MinValue

@Shadowghost
Copy link
Contributor

Indeed. But that should normally never happen...

@JRDevo
Copy link

JRDevo commented Sep 5, 2022

Version 20.0.0.0 solved this for me, thanks!

@Shadowghost
Copy link
Contributor

My guess is that the main problem was caused by old versions of the plugin not setting the expiration date of the access token properly. We now have a fallback which seems to fix this cases (reauthentication should have done the trick too).

Please reopen or create a new issue if this comes up after you removed the config file and reauthed your user.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This PR or Issue describes or fixes something that isn't working
Projects
None yet
Development

No branches or pull requests

8 participants