adamgot / python-plexlibrary

Create and maintain dynamic Plex libraries based on recipes.
BSD 3-Clause "New" or "Revised" License
204 stars 40 forks source link

Multiple Rankings in Movie Title #37

Open mapleleafs89 opened 6 years ago

mapleleafs89 commented 6 years ago

Great application, my plex users enjoy having the extended movie lists. Having one issue where sometimes movie titles when using the ranked number in title it seems to insert rankings over and over, not sure if this is over time (I run a daily update in cron) and it keeps inserting a new ranking without removing the old or if it's just doing it all in one run.

https://i.imgur.com/1Xme3Xr.png

Recipe [root@centos7 python-plexlibrary]# cat recipes/movies_bestof2018.yml

Supported types: movie, tv

library_type: 'movie'

Source list(s)

source_list_urls:

Source library details

source_libraries:

New library details

new_library: name: 'Movies (Best of 2018)' folder: '/mnt/media/movies-rottentomato-bestof2018/' sort: yes sort_title: format: '{number}. {title}' visible: yes absolute: yes # Skips numbers for missing items

Limit the age (in years) of items to be considered

* 0 for no limit

max_age: 2

Maximum number of items to keep in the library

max_count: 250

Remove items that no longer exist in the source lists

remove_from_library: no

Weighted sorting (requires TMDb API)

weighted_sorting: enabled: yes better_release_date: no weights:

Think of these as percentages,

# but they don't have to add up to 1.0
# * Additive
# * Higher value -> more important
index: 0.0
vote: 0.7
age: 0.3
random: 0.0
# Penalize (<0) or reward (>0) certain (TMDb) genres
# * Final weight is multipled by these values
genre_bias:
  'TV Movie': 0.7
  'Animation': 0.95
mapleleafs89 commented 6 years ago

I deleted the Library and re-added, all was fine on first run (aside from one movie missing the sort title ranking). I ran another update on the library and I saw some movies get the sort title appended to the front again, but others did not. So it seems the issue is coming when running a refresh on an existing library.

geekcroft commented 6 years ago

Remove the numeric sort insert - your movies will still sort by the same ranking but will not have the confusing/changing numbers (if I am interpreting the issue correctly that is)

mapleleafs89 commented 6 years ago

I see, I guess I can use that as a workaround. Would be nice to have the numbers in the title to make it obvious for the users they are ranked. Otherwise they probably wouldn't know.

adamgot commented 6 years ago

Hey guys, I’ll look into this as soon as I am able (few days).

mapleleafs89 commented 6 years ago

Thank you @adamgot !

mapleleafs89 commented 6 years ago

Any luck with this @adamgot ?