mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-01-23 23:20:51 +01:00
[Bug] Playback fails with http error 400 when playing with kodi, jellyfin for android, findroid #7590
Labels
No labels
area:database
awaiting-feedback
backend
blocked
breaking change: web api
bug
build
ci
confirmed
discussion needed
dotnet future
downstream
duplicate
EFjellyfin.db
enhancement
feature
future
github-actions
good first issue
hdr
help wanted
invalid
investigation
librarydb
live-tv
lyrics
media playback
music
needs testing
nuget
performance
platform
pull-request
question
regression
release critical
requires-web
roadmap
security
security
stale
support
syncplay
ui & ux
upstream
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: starred/jellyfin#7590
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @saikimecky on GitHub (Oct 27, 2025).
Description of the bug
After upgrading to Jellyfin.Server 10.11.1.0 playback with Kodi and the Jellyfin-kodi-plugin fails. Kodi throws an error message: "General error", in kodi.log i can see a http 400 Error.
Reproduction steps
What is the current bug behavior?
Movie doesnt load/playback on Kodi.
Worked in Versions before 10.11.1.0.
Please ignore the timestamps in the logs. They differ cause i ran the test multiple times. Clients and Server are in time sync ;)
What is the expected correct behavior?
Movies should play with kodi and kodi-plugin.
Jellyfin Server version
10.10.0+
Specify commit id
No response
Specify unstable release number
No response
Specify version number
Jellyfin.Server 10.11.1.0
Specify the build version
10.11.0
Environment
Jellyfin logs
FFmpeg logs
Client / Browser logs
2025-10-27 12:33:31.664 T:19353 info : JELLYFIN -> INFO::jellyfin_kodi/jellyfin/init.py:98 ---[ START JELLYFINCLIENT ]---
2025-10-27 12:33:31.674 T:19353 info : JELLYFIN.jellyfin_kodi.entrypoint.default -> INFO::jellyfin_kodi/entrypoint/default.py:90 path: ?filename=Easy+Rider+%281969%29+1080p+AC3.mkv&id=86d57009047fd95f05ddb40c851936fa&dbid=1222&mode=play params: {
"filename": "Easy Rider (1969) 1080p AC3.mkv",
"id": "86d57009047fd95f05ddb40c851936fa",
"dbid": "1222",
"mode": "play"
}
2025-10-27 12:33:31.869 T:19353 info : JELLYFIN.jellyfin_kodi.objects.actions -> INFO::jellyfin_kodi/objects/actions.py:72 [ play/86d57009047fd95f05ddb40c851936fa ] Easy Rider
2025-10-27 12:33:32.080 T:19353 info : JELLYFIN.jellyfin_kodi.helper.playutils -> INFO::jellyfin_kodi/helper/playutils.py:83 {'MediaSources': [{'Protocol': 'File', 'Id': '86d57009047fd95f05ddb40c851936fa', 'Path': '/srv/Datenpool/Datengrab/kodi/Filme/Easy Rider (1969)/Easy Rider (1969) 1080p AC3.mkv', 'Type': 'Default', 'Container': 'mkv', 'Size': 3066564439, 'Name': 'Easy Rider (1969) 1080p AC3', 'IsRemote': False, 'ETag': '2c068cb708fc4bab79d44ce80cfb1f68', 'RunTimeTicks': 57338110000, 'ReadAtNativeFramerate': False, 'IgnoreDts': False, 'IgnoreIndex': False, 'GenPtsInput': False, 'SupportsTranscoding': True, 'SupportsDirectStream': True, 'SupportsDirectPlay': True, 'IsInfiniteStream': False, 'UseMostCompatibleTranscodingProfile': False, 'RequiresOpening': False, 'RequiresClosing': False, 'RequiresLooping': False, 'SupportsProbing': True, 'VideoType': 'VideoFile', 'MediaStreams': [{'Codec': 'hevc', 'ColorSpace': 'bt709', 'ColorTransfer': 'bt709', 'ColorPrimaries': 'bt709', 'TimeBase': '1/1000', 'VideoRange': 'SDR', 'VideoRangeType': 'SDR', 'AudioSpatialFormat': 'None', 'DisplayTitle': '1080p HEVC SDR', 'IsInterlaced': False, 'IsAVC': False, 'BitRate': 4278570, 'BitDepth': 8, 'RefFrames': 1, 'IsDefault': True, 'IsForced': False, 'IsHearingImpaired': False, 'Height': 1040, 'Width': 1920, 'AverageFrameRate': 23.976025, 'RealFrameRate': 23.976025, 'ReferenceFrameRate': 23.976025, 'Profile': 'Main', 'Type': 'Video', 'AspectRatio': '1.85:1', 'Index': 0, 'IsExternal': False, 'IsTextSubtitleStream': False, 'SupportsExternalStream': False, 'PixelFormat': 'yuv420p', 'Level': 120, 'IsAnamorphic': False}, {'Codec': 'ac3', 'Language': 'deu', 'TimeBase': '1/1000', 'VideoRange': 'Unknown', 'VideoRangeType': 'Unknown', 'AudioSpatialFormat': 'None', 'LocalizedDefault': 'Standard', 'LocalizedExternal': 'Extern', 'DisplayTitle': 'Deutsch - Dolby Digital - 5.1 - Standard', 'IsInterlaced': False, 'IsAVC': False, 'ChannelLayout': '5.1', 'BitRate': 640000, 'Channels': 6, 'SampleRate': 48000, 'IsDefault': True, 'IsForced': True, 'IsHearingImpaired': False, 'Type': 'Audio', 'Index': 1, 'IsExternal': False, 'IsTextSubtitleStream': False, 'SupportsExternalStream': False, 'Level': 0}, {'Codec': 'ac3', 'Language': 'eng', 'TimeBase': '1/1000', 'VideoRange': 'Unknown', 'VideoRangeType': 'Unknown', 'AudioSpatialFormat': 'None', 'LocalizedDefault': 'Standard', 'LocalizedExternal': 'Extern', 'DisplayTitle': 'Englisch - Dolby Digital - 5.1', 'IsInterlaced': False, 'IsAVC': False, 'ChannelLayout': '5.1', 'BitRate': 640000, 'Channels': 6, 'SampleRate': 48000, 'IsDefault': False, 'IsForced': False, 'IsHearingImpaired': False, 'Type': 'Audio', 'Index': 2, 'IsExternal': False, 'IsTextSubtitleStream': False, 'SupportsExternalStream': False, 'Level': 0}], 'MediaAttachments': [], 'Formats': [], 'Bitrate': 5558570, 'RequiredHttpHeaders': {}, 'TranscodingSubProtocol': 'http', 'DefaultAudioStreamIndex': 1, 'HasSegments': True}], 'PlaySessionId': 'cafd52b0e24b4337b48ae81302815cb6'}
2025-10-27 12:33:32.089 T:19353 info : JELLYFIN.jellyfin_kodi.helper.playutils -> INFO::jellyfin_kodi/helper/playutils.py:100 Skip source selection.
2025-10-27 12:33:32.106 T:19353 info : JELLYFIN.jellyfin_kodi.helper.playutils -> INFO::jellyfin_kodi/helper/playutils.py:209 --[ direct stream ]
2025-10-27 12:33:32.422 T:19353 warning : ListItem.setCast() is deprecated and might be removed in future Kodi versions. Please use InfoTagVideo.setCast().
2025-10-27 12:33:32.437 T:19353 warning : "totaltime" in ListItem.setProperty() is deprecated and might be removed in future Kodi versions. Please use InfoTagVideo.setResumePoint().
2025-10-27 12:33:32.437 T:19353 warning : "resumetime" in ListItem.setProperty() is deprecated and might be removed in future Kodi versions. Please use InfoTagVideo.setResumePoint().
2025-10-27 12:33:32.438 T:19353 warning : ListItem.addStreamInfo() is deprecated and might be removed in future Kodi versions. Please use InfoTagVideo.addVideoStream(), InfoTagVideo.addAudioStream() and InfoTagVideo.addSubtitleStream().
2025-10-27 12:33:32.438 T:19353 info : Skipped 2 duplicate messages..
2025-10-27 12:33:32.438 T:19353 warning : Setting most video properties through ListItem.setInfo() is deprecated and might be removed in future Kodi versions. Please use the respective setter in InfoTagVideo.
2025-10-27 12:33:32.451 T:19353 info : JELLYFIN.main -> INFO::default.py:25 ---<[ default ]
2025-10-27 12:33:32.483 T:17245 info : VideoPlayer::OpenFile: plugin://plugin.video.jellyfin/7a2175bccb1f1a94152cbd2b2bae8f6d/?filename=Easy+Rider+%281969%29+1080p+AC3.mkv&id=86d57009047fd95f05ddb40c851936fa&dbid=1222&mode=play
2025-10-27 12:33:32.485 T:19359 info : Creating InputStream
2025-10-27 12:33:32.517 T:19359 error : CCurlFile::CReadState::FillBuffer - (0x7c6e0140) Failed: HTTP returned code 400
2025-10-27 12:33:32.517 T:19359 error : CCurlFile::Open - http://192.168.180.106:8096/Videos/86d57009047fd95f05ddb40c851936fa/stream?static=true&MediaSourceId=86d57009047fd95f05ddb40c851936fa&api_key=f50480ea1fd742d885f582a1fd3aa571 Failed with code 400:
2025-10-27 12:33:32.518 T:19359 error : CFileCache::Open - http://192.168.180.106:8096/Videos/86d57009047fd95f05ddb40c851936fa/stream?static=true&MediaSourceId=86d57009047fd95f05ddb40c851936fa&api_key=f50480ea1fd742d885f582a1fd3aa571 failed to open
2025-10-27 12:33:32.518 T:19359 error : CVideoPlayer::OpenInputStream - error opening [plugin://plugin.video.jellyfin/7a2175bccb1f1a94152cbd2b2bae8f6d/?filename=Easy+Rider+%281969%29+1080p+AC3.mkv&id=86d57009047fd95f05ddb40c851936fa&dbid=1222&mode=play]
2025-10-27 12:33:32.518 T:19359 info : CVideoPlayer::OnExit()
2025-10-27 12:33:32.529 T:17325 info : Deleting settings information for files plugin://plugin.video.jellyfin/7a2175bccb1f1a94152cbd2b2bae8f6d/?filename=Easy+Rider+%281969%29+1080p+AC3.mkv&id=86d57009047fd95f05ddb40c851936fa&dbid=1222&mode=play
2025-10-27 12:33:32.613 T:17245 info : CVideoPlayer::CloseFile()
2025-10-27 12:33:32.614 T:17245 info : VideoPlayer: waiting for threads to exit
2025-10-27 12:33:32.614 T:17245 info : VideoPlayer: finished waiting
2025-10-27 12:33:32.675 T:17331 error : EXCEPTION: Kodi is not playing any file
2025-10-27 12:33:32.797 T:17382 info : Skipped 2 duplicate messages..
2025-10-27 12:33:32.796 T:17382 info : JELLYFIN.jellyfin_kodi.objects.actions -> INFO::jellyfin_kodi/objects/actions.py:863 [ play ] kodi_id: 1222 media: movie
2025-10-27 12:33:32.928 T:17382 info : JELLYFIN.jellyfin_kodi.player -> INFO::jellyfin_kodi/player.py:394 --<[ playback ]
2025-10-27 12:33:36.031 T:17382 info : JELLYFIN.jellyfin_kodi.monitor -> INFO::jellyfin_kodi/monitor.py:105 [ playlist ] cleared
2025-10-27 12:33:36.032 T:17382 error : EXCEPTION: Kodi is not playing any file
2025-10-27 12:33:39.270 T:17245 info : Skipped 3 duplicate messages..
2025-10-27 12:33:39.270 T:17245 info : Loading skin file: Settings.xml, load type: KEEP_IN_MEMORY
2025-10-27 12:33:40.044 T:17382 info : JELLYFIN.jellyfin_kodi.player -> INFO::jellyfin_kodi/player.py:72 Cancel playback report
2025-10-27 12:33:41.322 T:17245 info : Attempting to default to:
2025-10-27 12:33:41.323 T:17245 info : Loading skin file: FileManager.xml, load type: KEEP_IN_MEMORY
2025-10-27 12:33:52.218 T:17245 info : Loading skin file: DialogTextViewer.xml, load type: KEEP_IN_MEMORY
Relevant screenshots or videos
No response
Additional information
No response
@saikimecky commented on GitHub (Oct 28, 2025):
Further testing: Playback fails with "Source Error" on Findroid and the native jellyfin android app, too.
@FerrahWolfeh commented on GitHub (Oct 28, 2025):
This seems to be related to bad parsing of some MKV files.
I've been digging through my library and this error occurs mostly when the video file (in my case) is a mkv file with an av1 video stream, an opus audio stream, subtitles and font file attachments. Apparently, jellyfin misinterprets these files as webm instead of mkv and fails to parse both subs and attachments without resorting to transcoding instead of remuxing.
When I converted this same file to hevc, direct play and HLS remux started working as usual.
@saikimecky commented on GitHub (Oct 28, 2025):
Oh yes, its the same here. h264 works. h265 not.
Thought it got something to do with ffmpeg7. so i tried downgrading this with no success. ffmpeg7 seems not responsible for the errors we see.
@leo9800 commented on GitHub (Nov 3, 2025):
I could confirm this issue and did some further investigations:
mkv) either..mp4containered videos also failed playbacks.https://jellyfin.invalid.test/Videos/21da73ec28cd4ed128384ec61cec51fa/stream.mkv?Static=true&mediaSourceId=21da73ec28cd4ed128384ec61cec51fa&deviceId=SmVsbHlmaW5NZWRpYVBsYXllciAxLjEyLjAgKGxpbnV4LXg4Nl82NCB1bmtub3duKXwxNzQzNTA2OTQxNzkw&ApiKey=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx&Tag=22c7c9d919c4f56cc2fed48b9abb31ebcurl https://jellyfin.invalid.test/Videos/21da73ec28cd4ed128384ec61cec51fa/stream.mkv?Static=true&mediaSourceId=21da73ec28cd4ed128384ec61cec51fa&deviceId=SmVsbHlmaW5NZWRpYVBsYXllciAxLjEyLjAgKGxpbnV4LXg4Nl82NCB1bmtub3duKXwxNzQzNTA2OTQxNzkw&ApiKey=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx&Tag=22c7c9d919c4f56cc2fed48b9abb31eb; vlc stream.mkvworked like a charmabove all i believe @saikimecky and @FerrahWolfeh were not correct, this issue is not codec/container-dependent. i believe it is somehow io/networking related. the log on my server indicates:
be noticed that parameter
countonly exists inMicrosoft.AspNetCore.Http.SendFileFallback.SendFileAsync(Stream destination, String filePath, Int64 offset, Nullable1 count, CancellationToken cancellationToken)`Microsoft.AspNetCore.Http.SendFileResponseExtensions.SendFileAsyncCore(HttpResponse response, String fileName, Int64 offset, Nullable1 count, CancellationToken cancellationToken)`and the out-of-bounded value is not exactly the same (
3066564439vs2595727369)@leo9800 commented on GitHub (Nov 3, 2025):
Update: ISSUE CAUSE IDENTIFIED, workarounds TBD ...
retrieved ssl random to master secret mapping by applying envvar
SSLKEYLOGFILEto apache http server acting as reverse proxy on my server which is required for decrypting ssl sessionsby decrypting, i noticed JMP sets 2 suspicious headers in
/Videos/{hash}/stream.mkvrequests:then I tried:
curl -v {url}-> results in 200curl -v -H 'Icy-MetaData: 1' {url}-> results in 200curl -v -H 'Icy-MetaData: 1' -H 'Range: bytes=0-' {url}-> results in 400curl -v -H 'Range: bytes=0-' {url}-> results also in 400interestingly,
curl -v -H 'Range: bytes=0-100' {url}results in 206, and the binary (octet-stream) in resp body is a valid (but truncated, definitely) matroska (mkv) payloadhowever, increase the range, i.e.
curl -v -H 'Range: bytes=0-8192' {url}, results in 400a dirty hack may be modify JMP code and remove the
rangeheader, but it does nothing with the root cause which is the server's fault.the root cause is that the server fails handling
rangeheader correctly somehow.@FerrahWolfeh commented on GitHub (Nov 3, 2025):
Interesting. So it wasn't any of the things I was expecting, but actually something deep inside the server...
But still, something happened in the new
10.11.2version that made this issue disappear for me completely. Findroid and the webplayer on brave are working fine with direct stream while playing the problematic files.Anyone can reproduce or confirm this?
@saikimecky commented on GitHub (Nov 3, 2025):
...
Updated to version 10.11.2. Still cant play in Programms, only Web works.
I still see the error when playing from kodi or get a "Source Error" in the jellyfin app:
System.InvalidOperationException: Response Content-Length mismatch: too few bytes written (25 of 387589374).@leo9800 commented on GitHub (Nov 12, 2025):
update: this issue may be caused by incorrect handling of symlinked media files
it may be fixed by #15263, which addressed the bug introduced by #15209 which is included in v10.11.1, by downgrading to v10.11.0 everything worked like a charm
p.s. i tried to reproduce this issue in a new setup but it just seems disappeared, it turns out to be the media files in the new (debug) setup were not symlinks while media files are symlinks on my production setup
@3flex commented on GitHub (Nov 17, 2025):
Updated to 10.11.3 and integrated player now works again for me on Jellyfin for Android.
@saikimecky commented on GitHub (Nov 18, 2025):
Works with 10.11.3 again :) Bug can be closed.