ghomasHudson / Jellyfin-Auto-Collections

Automatically make jellyfin collections from IMDB, Letterboxd lists and more.
MIT License
102 stars 12 forks source link

Error creating collections with mdblist #27

Closed BoHoliday closed 5 months ago

BoHoliday commented 5 months ago
2024-06-08 21:29:28.178 | INFO     | __main__:main:31 - Getting list info for plugin: mdblist, list id: xxxxxxx/popular-collection
2024-06-08 21:29:30.329 | INFO     | utils.jellyfin:find_collection_with_name_or_create:60 - found collection: Popular Collection (xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx)2024-06-08 21:29:30.348 | INFO     | utils.jellyfin:clear_collection:106 - Cleared collection xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Traceback (most recent call last):
  File "/app/main.py", line 45, in <module>
Getting collections list...
    main(config)
  File "/app/main.py", line 39, in main
    jf_client.add_item_to_collection(collection_id, item)
  File "/app/utils/jellyfin.py", line 75, in add_item_to_collection
    item["media_type"] = self.imdb_to_jellyfin_type_map.get(item["media_type"], item["media_type"])
KeyError: 'media_type'
ghomasHudson commented 5 months ago

Needed to rename a dictionary key - this should fix this now (Please pull the changes and reopen if it's still broken).