immich
immich copied to clipboard
Video on android not working
The bug
On mobile android app, when trying to play a video stored only on server side, initially a get a loading spinner, but after some seconds I get a completely black screen. This is the error log reported by the app:
#1 AsyncError.value (package:riverpod/src/common.dart:473:0)
#2 VideoViewerPage.build (package:immich_mobile/modules/asset_viewer/views/video_viewer_page.dart:37:0)
#3 _ConsumerState.build (package:flutter_riverpod/src/consumer.dart:479:0)
#4 StatefulElement.build (package:flutter/src/widgets/framework.dart:5583:0)
#5 ConsumerStatefulElement.build (package:flutter_riverpod/src/consumer.dart:542:0)
#6 HookElement.build (package:flutter_hooks/src/framework.dart:438:0)
#7 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:5471:0)
#8 StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:5634:0)
#9 Element.rebuild (package:flutter/src/widgets/framework.dart:5187:0)
#10 BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2895:0)
#11 WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:984:0)
#12 RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:457:0)
#13 SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1325:0)
#14 SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1255:0)
#15 SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:1113:0)
#16 _invoke (dart:ui/hooks.dart:312:0)
#17 PlatformDispatcher._drawFrame (dart:ui/platform_dispatcher.dart:383:0)
#18 _drawFrame (dart:ui/hooks.dart:283:0)
The OS that Immich Server is running on
debian
Version of Immich Server
v1.98.2
Version of Immich Mobile App
v1.98.2
Platform with the issue
- [ ] Server
- [ ] Web
- [X] Mobile
Your docker-compose.yml content
apk problem
Your .env content
apk problem
Reproduction steps
1. Have a video only stored on the server side
2. Try to play that video from mobile
Additional information
No response
Hello, do you use the default transcoding options and if you can share the problem video with us so we can reproduce and troubleshoot?
Yes, I'm using the default video transcoding, without hardware transcoding. It's not a video related problem since it happens on every video that I don't have downloaded on the phone but it's stored only server-side. From PC browser the videos are properly playing.
I cannot recreate the issue you are facing with my dataset, so I think it might be a certain type of video that is causing the bug, thus the request for your video.
I've just took a random video with my phone, uploaded using the PC and was able to reproduce the problem. I'm not sure if it is related to my configuration at this point. I think that it stopped working some versions ago of immich.
https://github.com/immich-app/immich/assets/11853645/852c387a-47b5-4a88-a925-fc4c0dbf999d
I can play the video just fine from my end on the mobile app and on the web. Can you go to the Administration > Settings page, then click on the Export JSON and compare it with my default settings for ffmpeg section?
"ffmpeg": {
"crf": 23,
"threads": 0,
"preset": "ultrafast",
"targetVideoCodec": "h264",
"acceptedVideoCodecs": [
"h264"
],
"targetAudioCodec": "aac",
"acceptedAudioCodecs": [
"aac",
"mp3",
"libopus"
],
"targetResolution": "720",
"maxBitrate": "0",
"bframes": -1,
"refs": 0,
"gopSize": 0,
"npl": 0,
"temporalAQ": false,
"cqMode": "auto",
"twoPass": false,
"preferredHwDevice": "auto",
"transcode": "required",
"tonemap": "hable",
"accel": "disabled"
},
Looks exactly the same as yours:
"ffmpeg": {
"crf": 23,
"threads": 0,
"preset": "ultrafast",
"targetVideoCodec": "h264",
"acceptedVideoCodecs": [
"h264"
],
"targetAudioCodec": "aac",
"acceptedAudioCodecs": [
"aac",
"mp3",
"libopus"
],
"targetResolution": "720",
"maxBitrate": "0",
"bframes": -1,
"refs": 0,
"gopSize": 0,
"npl": 0,
"temporalAQ": false,
"cqMode": "auto",
"twoPass": false,
"preferredHwDevice": "auto",
"transcode": "required",
"tonemap": "hable",
"accel": "disabled"
},
Are you accessing your instance over Local IP or DNS/Reverse Proxy?
Local IP over https using a self-signed certificate.
Can you access over local IP, http, without self-signed certificate?
Just tried and it was working fine, so it must be self-signed certificate related. Moreover, when re-configuring the app using https to restore my original configuration, the app got stuck during the configuration phase. Closing and re-opening it let it build the timeline but the video playing problem was still there.
There are numerous reported issues with self signed certs for movies such as issue #5553 and mine #4663
As someone mentioned, flutter has its own cert store so it can't accept self signed unless flutter itself changes that in it's library.
Is this old issue going to be fixed? It makes the app unusable. The problem is also present with a valid Let's Encrypt certificate
Dupe: #5553