pannal / plex-for-kodi

Unoffical Plex for Kodi add-on releases.
GNU General Public License v2.0
237 stars 30 forks source link

external subtitles are not displayed #114

Closed lhg1026 closed 3 days ago

lhg1026 commented 1 month ago

Description: After installing PM4K on NVIDIA Shield TV, when playing HDR videos on an old TV that doesn’t support HDR, the external subtitles are not displayed, which may be due to the loss of PM4K’s software decoding.

Details:

Checklist

TRaSH- commented 1 month ago

I recently switched to this skin to give it a test, but i also noticed it doesn't load external SRT subs and i don't think it's related to SDR/HDR/DV or anything HDR formats related. it just doesn't load the external SRT subs. The internal SRT subs aren't a issue

With my first tests i also noticed this is something that only happens on the shield with this theme, when i install it on my laptop it does work.

pannal commented 1 month ago

Still no debug logs guys. Or any Screenshots.

TRaSH- commented 1 month ago

Screenshots would be useless because there isn't much to see. :D

But I'll try to provide a debug log this evening when I get home from work.

TRaSH- commented 1 month ago

https://paste.kodi.tv/deleted.kodi

started with external dutch subs, then switch to embedded SRT subs then switched back to external english subs. Embedded SRT subs work, external subs doesn't show up. let me know if you need more episode i used for this test The.Walking.Dead.The.Ones.Who.Live.S01E01

pannal commented 4 weeks ago

Attention, you have your plex token inside the log!

And yes, I do see your subtitles failing, e.g.:

2024-06-04 20:10:26.292 T:19803    info <general>: Opening stream: 0 source: 1024
2024-06-04 20:10:26.292 T:19803   debug <general>: CFileCache::Open - <https://plex.xxx.xyz:443/library/streams/696163?encoding=utf-8&X-Plex-Token=XXXXXXXXXXXXXXXXX> opening
2024-06-04 20:10:26.293 T:19815   debug <general>: CDVDAudio::Pause - pausing audio stream
2024-06-04 20:10:26.293 T:19803   debug <general>: CurlFile::Open - <https://plex.xxx.xyz:443/library/streams/696163?encoding=utf-8&X-Plex-Token=XXXXXXXXXXXXXXXXX>
2024-06-04 20:10:26.314 T:19715    info <general>: script.plex: Monitoring video...
2024-06-04 20:10:26.338 T:19803   error <general>: CCurlFile::CReadState::FillBuffer - (0x214c2597f0) Failed: HTTP returned code 502
2024-06-04 20:10:26.338 T:19803   error <general>: CCurlFile::Open - <https://plex.xxx.xyz:443/library/streams/696163?encoding=utf-8&X-Plex-Token=XXXXXXXXXXXXXXXXX> Failed with code 502:

2024-06-04 20:10:26.338 T:19803   error <general>: CFileCache::Open - <https://plex.xxx.xyz:443/library/streams/696163?encoding=utf-8&X-Plex-Token=XXXXXXXXXXXXXXXXX> failed to open
2024-06-04 20:10:26.338 T:19803   error <general>: OpenStream - Unable to create subtitle parser
2024-06-04 20:10:26.338 T:19803    info <general>: Opening stream: 0 source: 1024
2024-06-04 20:10:26.339 T:19803   debug <general>: CFileCache::Open - <https://plex.xxx.xyz:443/library/streams/696163?encoding=utf-8&X-Plex-Token=XXXXXXXXXXXXXXXXX> opening
2024-06-04 20:10:26.339 T:19803   debug <general>: CurlFile::Open - <https://plex.xxx.xyz:443/library/streams/696163?encoding=utf-8&X-Plex-Token=XXXXXXXXXXXXXXXXX>
2024-06-04 20:10:26.344 T:19803   error <general>: CCurlFile::CReadState::FillBuffer - (0x214c2597f0) Failed: HTTP returned code 502
2024-06-04 20:10:26.345 T:19803   error <general>: CCurlFile::Open - <https://plex.xxx.xyz:443/library/streams/696163?encoding=utf-8&X-Plex-Token=XXXXXXXXXXXXXXXXX> Failed with code 502:

2024-06-04 20:10:26.345 T:19803   error <general>: CFileCache::Open - <https://plex.xxx.xyz:443/library/streams/696163?encoding=utf-8&X-Plex-Token=XXXXXXXXXXXXXXXXX> failed to open
2024-06-04 20:10:26.345 T:19803   error <general>: OpenStream - Unable to create subtitle parser

Can you try opening the failing URL manually?

TRaSH- commented 4 weeks ago

thnx, shame the kodi logs don't get cleaned, finding all the domain names and keys is kind a pain in the logs

let me try a new test, because i don't have the old logs anymore, tested it with a new one, and yes i can open it and i see the subtitles

pannal commented 2 weeks ago

Can this be closed? Did you find the root cause so anyone else with the same problem can take a shortcut?

TRaSH- commented 2 weeks ago

Well, I was actually waiting for feedback from you after I tested what you asked!

But I think I might have found the issue. Somehow, the 'advancedsettings.xml' that was edited/created by PM4K had a huge list of entries to unknown IP addresses, including LAN/WAN addresses that aren't familiar to me. I noticed this when I was looking at the logs and wondered why it was using my reverse proxy URL instead of my LAN IP range. So I deleted the advancedsettings.xml and let PM4K recreate it, which resulted in a new file. Now it only has one entry, containing only my WAN IP address. What's strange is that when I asked someone else to do the same, theirs also contained their LAN IP address, but even after multiple deletions, mine didn't add my LAN address back. In the end, I manually added my LAN address to the settings inside PM4K, and now when I start playback, it shows in the logs:

VideoPlayer::OpenFile: http://192.168.2.200:32400/library/parts/1 and the same LAN IP when I use external subs, and that solved the sub issue.

I now have another issue that the video/audio starts to lag after a certain time but I will open a new issue tracker for that later.

pannal commented 2 weeks ago

What's strange is that when I asked someone else to do the same, theirs also contained their LAN IP address, but even after multiple deletions, mine didn't add my LAN address back.

That's normal, those access URIs are generated by Plex and PM4K resolves them (normally only the plex.direct ones, to avoid DNS rebind issues). You can see your server's connection URIs by accessing https://clients.plex.tv/devices.xml?X-Plex-Token=YOUR_TOKEN.

Why those LAN IPs haven't come back, I'm not sure.

TRaSH- commented 1 week ago

well it solved for now, so you can close it if you want to. i'm not the original OP

pannal commented 1 week ago

Closing for now. Please reopen if necessary