mza921 / Plex-Auto-Collections

Python 3 script to automatically update Plex collections based off a configuration file
311 stars 28 forks source link

Issue with tmdb_writer and TMDB photo #118

Closed bigdork closed 3 years ago

bigdork commented 3 years ago

Crash when TMDB missing photo, maybe others than tmdb_writer but I've not encountered. I'll be uploading images to TMDB for the writers I'm having trouble with, but FYI:

  Writer Dean Koontz:
    sort_title: -5 Writer Dean Koontz
    tmdb_writer: 29923
| Updating collection: Writer Dean Koontz...
| Sync Mode: append
Traceback (most recent call last):
  File "/opt/scripts/Plex-Auto-Collections/app/plex_auto_collections.py", line 986, in <module>
    update_from_config(config_path, plex, True, args.no_meta, args.no_images)
  File "/opt/scripts/Plex-Auto-Collections/app/plex_auto_collections.py", line 408, in update_from_config
    details["poster"] = ["url", tmdb_get_metadata(config_path, id, "profile_path"), method_name]
  File "/opt/scripts/Plex-Auto-Collections/app/imdb_tools.py", line 507, in tmdb_get_metadata
    return tmdb_url_prefix + person.details(id).profile_path
TypeError: must be str, not NoneType
meisnate12 commented 3 years ago

nice catch ill add in something to check for this and let the user know no photo was found on tmdb

bigdork commented 3 years ago

I uploaded photos but still crashing, probably need to wait a little bit. If it's not that, these are the people I added that are crashing the script:

  Writer Dean Koontz:
    tmdb_writer: 29923
  Writer James Patterson:
    tmdb_writer: 21022
  Writer John Grisham:
    tmdb_writer: 11060
  Writer Tom Clancy:
    tmdb_writer: 38568
meisnate12 commented 3 years ago

it probably hasn't updated on their end I'd give it 24 hours