wilmardo / migrate-plex-to-jellyfin

Migrate watched status from Plex to Jellyfin
99 stars 22 forks source link

Skip if path is not avaliable #29

Open phazejeff opened 4 months ago

phazejeff commented 4 months ago

Fixes issue #28

wilmardo commented 4 months ago

Thanks for the PR!

When does this occur? Are there items in Jellyfin without a path is that possible?

Nice to know that this script is still useful for people :)

tellebma commented 4 months ago

This may be due to a Jellyfin plugin notifies you of missing episodes. I print the source (l58)

for jf_entry in jf_library:
    for source in jf_entry.get("MediaSources", []):
        print(source)
        if source["Path"] not in jf_entries:
            jf_entries[source["Path"]] = [jf_entry]

And i got {'Protocol': 'File', 'Id': '00038f635acfdcf175ae19361ea4b124', 'Type': 'Placeholder', 'Name': "Inside 'Vindicators 3: The Return of Worldender'", 'IsRemote': False, 'ETag': 'a943be3832e36acf4c9f18fd7337a26f', 'ReadAtNativeFramerate': False, 'IgnoreDts': False, 'IgnoreIndex': False, 'GenPtsInput': False, 'SupportsTranscoding': True, 'SupportsDirectStream': True, 'SupportsDirectPlay': True, 'IsInfiniteStream': False, 'RequiresOpening': False, 'RequiresClosing': False, 'RequiresLooping': False, 'SupportsProbing': True, 'VideoType': 'VideoFile', 'MediaStreams': [], 'MediaAttachments': [], 'Formats': [], 'RequiredHttpHeaders': {}, 'TranscodingSubProtocol': 'http'}

Inside 'Vindicators 3: The Return of Worldender' on my Jellyfin image

Thx for your script btw :)

phazejeff commented 4 months ago

Pretty much same for me, I don't have that plugin but it occurs on episodes that are listed in Jellyfin as part of the show but isn't available on disk. "Special" episodes were most guilty of this