Jump to content

Subtitles cannot be displayed


Recommended Posts

Posted

HI, please attach the corresponding emby server log as well. thanks.

Posted

Is it a well-formed srt? Notice this in your log:
 

2023-05-30 01:52:12.226 Error App: Error getting subtitles
	*** Error Report ***
	Version: 4.7.12.0
	Command line: /opt/emby-server/system/EmbyServer.dll -programdata /var/lib/emby -ffdetect /opt/emby-server/bin/ffdetect -ffmpeg /opt/emby-server/bin/ffmpeg -ffprobe /opt/emby-server/bin/ffprobe -restartexitcode 3 -updatepackage emby-server-deb_{version}_amd64.deb
	Operating system: Linux version 5.19.17-2-pve (build@proxmox) (gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2) #1 SMP PREEMPT_DYNAMIC PV
	Framework: .NET 6.0.14
	OS/Process: x64/x64
	Runtime: opt/emby-server/system/System.Private.CoreLib.dll
	Processor count: 4
	Data path: /var/lib/emby
	Application path: /opt/emby-server/system
	System.Exception: System.Exception: ffmpeg subtitle conversion failed for /mnt/Movies/电影/速度与激情1 (2001)/速度与激情1 (2001) 2160p DTS-X.chs.default.srt
	   at Emby.Server.MediaEncoding.Subtitles.SubtitleEncoder.ConvertExternalSubtitleInternal(MediaStream subtitleStream, IDictionary`2 requestHeaders, String outputPath, SubtitleMediaTypes outputCodec, Nullable`1 startTime, Nullable`1 endTime, Boolean preserveOriginalTimestamps, CancellationToken cancellationToken)
	   at Emby.Server.MediaEncoding.Subtitles.SubtitleEncoder.ConvertExternalSubtitle(MediaStream subtitleStream, IDictionary`2 requestHeaders, String outputPath, SubtitleMediaTypes outputCodec, Nullable`1 startTime, Nullable`1 endTime, Boolean preserveOriginalTimestamps, CancellationToken cancellationToken)
	   at Emby.Server.MediaEncoding.Subtitles.SubtitleEncoder.GetReadableFile(String mediaPath, MediaProtocol mediaSourceProtocol, Boolean isAudio, IDictionary`2 requestHeaders, MediaStream subtitleStream, String outputFormat, Int64 startTimeTicks, Int64 endTimeTicks, Boolean preserveOriginalTimestamps, EncodingContext encodingContext, CancellationToken cancellationToken)
	   at Emby.Server.MediaEncoding.Subtitles.SubtitleEncoder.GetSubtitles(String inputPath, MediaProtocol inputProtocol, Boolean isAudio, IDictionary`2 requestHeaders, MediaStream subtitleStream, String outputFormat, Int64 startTimeTicks, Int64 endTimeTicks, Boolean preserveOriginalTimestamps, EncodingContext encodingContext, CancellationToken cancellationToken)
	   at Emby.Api.Subtitles.SubtitleService.GetSubtitles(GetSubtitle request, CancellationToken cancellationToken)
	   at Emby.Api.Subtitles.SubtitleService.Get(GetSubtitle request)
	Source: Emby.Server.MediaEncoding
	TargetSite: Void MoveNext()

 

Posted

The problem has been solved.

1.Coding issues:The original file is utf8-bom, you need to change it to utf8

2.The initial location of the file does not identify the corresponding data

errorimage.thumb.png.3909be4b3917e65aaa4b9a5c819e4707.png

Normal display

image.thumb.png.6d1b482310ee1e52267ef9d260463e49.png

One suggestion: is it possible to display more specific and detailed information in the logs?

  • Thanks 1
Posted
3 hours ago, hywell said:

The problem has been solved.

1.Coding issues:The original file is utf8-bom, you need to change it to utf8

2.The initial location of the file does not identify the corresponding data

errorimage.thumb.png.3909be4b3917e65aaa4b9a5c819e4707.png

Normal display

image.thumb.png.6d1b482310ee1e52267ef9d260463e49.png

One suggestion: is it possible to display more specific and detailed information in the logs?

Hi, yes we can look at the error logging but it’s often coming from ffmpeg and not our own code.

Posted

Can emby improve compatibility: automatically handle subtitle file encoding and format validation. If it can't be handled automatically, can it be indicated in the log?

Posted
13 hours ago, hywell said:

Can emby improve compatibility: automatically handle subtitle file encoding and format validation. If it can't be handled automatically, can it be indicated in the log?

Well we don’t really know that it’s going to be a problem until we try to run it through ffmpeg. I do think that adding the 1 at the top of the srt is something we can try to check for and recover from.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...