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

TypeError: '<' not supported between instances of 'Movie' and 'Movie' #74

Closed
glensc opened this issue Sep 27, 2020 · 4 comments · Fixed by #76
Closed

TypeError: '<' not supported between instances of 'Movie' and 'Movie' #74

glensc opened this issue Sep 27, 2020 · 4 comments · Fixed by #76

Comments

@glensc
Copy link
Collaborator

glensc commented Sep 27, 2020

Processing section TV Shows
Traceback (most recent call last):
  File "/home/glen/scm/mediaserver/plex/Plugins/PlexTraktSync/main.py", line 354, in <module>
    main()
  File "/home/glen/scm/mediaserver/plex/Plugins/PlexTraktSync/main.py", line 345, in main
    listutil.updatePlexLists(plex)
  File "/home/glen/scm/mediaserver/plex/Plugins/PlexTraktSync/trakt_list_util.py", line 61, in updatePlexLists
    l.updatePlexList(plex)
  File "/home/glen/scm/mediaserver/plex/Plugins/PlexTraktSync/trakt_list_util.py", line 36, in updatePlexList
    _, plex_movies_sorted = zip(*sorted(self.plex_movies))
TypeError: '<' not supported between instances of 'Movie' and 'Movie'
@glensc
Copy link
Collaborator Author

glensc commented Sep 28, 2020

The error went away after a retry (because requests cached?), but worth researching what happened.

@simonc56
Copy link
Collaborator

Maybe you have the same movie in differents libraries.
I know how to fix this.

@glensc
Copy link
Collaborator Author

glensc commented Sep 28, 2020

Yes, very likely, I have "Movies" and "Movies (Archive)" libraries, so I do move the files around.

@simonc56
Copy link
Collaborator

I wonder what is the expected behavior in such situation.

Example : in your trakt watchlist at rank 2 you have The Mask movie.
And you have The Mask in 720p in Plex library Kids, The Mask 1080p in library Movies and The Mask 3D in library 3D Movies. All are the same movie from 1994 so have the same id.

If you sync all those libraries, which version of the movie do you expect to be added in the Plex playlist "Trakt watchlist" ?

I would say the first found, so if libraries are sync alphabetically, it would be the 3D version. 😄
If you add the 3 versions, it would mess up the list and ranks.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants