Unable to record mobile screen

**Hi ** :slightly_smiling_face:,
I’m running automation tests and trying to record simulator’s screen (iPhone 12) but it keeps crashing on line:
(source: https://appium.io/docs/en/commands/device/recording-screen/start-recording-screen/)

[ffmpeg] ffmpeg version 5.1 Copyright © 2000-2022 the FFmpeg developers
[ffmpeg] built with Apple clang version 13.1.6 (clang-1316.
[ffmpeg] configuration: --prefix=/opt/homebrew/Cellar/ffmpeg/5.1 --enable-shared --enable-pthreads --enable-version3 --cc=clang --host-cflags= --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libdav1d --enable-libmp3lame --enable-libopus --enable-librav1e --enable-librist --enable-librubberband --enable-libsnappy --enable-libsrt --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libspeex --enable-libsoxr --enable-libzmq --enable-libzimg --disable-libjack --disable-indev=jack --enable-videotoolbox --enable-neon
[ffmpeg] libavutil 57. 28.100 / 57. 28.100
[ffmpeg] libavcodec 59. 37.100 / 59. 37.100
[ffmpeg] libavformat 59. 27.100 / 59. 27.100
[ffmpeg] libavdevice 59. 7.100 / 59. 7.100
[ffmpeg] libavfilter 8. 44.100 / 8. 44.100
[ffmpeg] libswscale 6. 7.100 / 6. 7.100
[ffmpeg] libswresample 4. 7.100 / 4. 7.100
[ffmpeg] libpostproc 56. 6.100 / 56. 6.100
[ffmpeg] [mjpeg @ 0x1376052f0] No JPEG data found in image
[ffmpeg] [mjpeg @ 0x137704280] Could not find codec parameters for stream 0 (Video: mjpeg, none(bt470bg/unknown/unknown)): unspecified size
[ffmpeg] Consider increasing the value for the ‘analyzeduration’ (0) and ‘probesize’ (5000000) options
[ffmpeg] Input #0, mjpeg, from ‘’:
[ffmpeg] Duration: N/A, bitrate: N/A
[ffmpeg] Stream #0:0: Video: mjpeg, none(bt470bg/unknown/unknown), 25 tbr, 1200k tbn
[ffmpeg] Stream mapping:
[ffmpeg] Stream #0:0 -> #0:0 (mjpeg (native) -> mjpeg (native))
[ffmpeg] Press [q] to stop, [?] for help
[ffmpeg] [mjpeg @ 0x138804870] No JPEG data found in image
[ffmpeg] Error while decoding stream #0:0: Invalid data found when processing input
[ffmpeg] Cannot determine format of input stream 0:0 after EOF
[ffmpeg] Error marking filters as finished
[ffmpeg] Conversion failed!

Appium version: 1.22.3
Tests env: Python

Anyone knows how to solve this issue ? :weary:
Thank you ! :pray:t2:

You don’t really give many details at all about what you are trying to do, but maybe you are using iOS and will find this article helpful:


I am trying to record screen on simulator - iPhone 12
I initiated the driver and the flow works fine (find element, click , etc’)
but when I tries execute the command driver.start_recording_screen() I get this logs of ffmpeg.

  1. double check that ‘ffmpeg’ installed on machine where appium server runs
  2. play with videoType parameter e.g. set it to mpeg4 or h264
  3. add your code to understand