Page MenuHomePhabricator

Error creating thumbnail for webm video
Closed, ResolvedPublic

Description

Thumbnails fail at all sizes:

https://upload.wikimedia.org/wikipedia/commons/thumb/6/6a/Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm/640px--Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm.jpg

Error creating thumbnail: '/usr/bin/ffmpeg' -threads 1 -ss 140 -y -i 'http://ms-fe.svc.eqiad.wmnet/v1/AUTH_mw/wikipedia-commons-local-public.6a/6/6a/Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm?temp_url_sig=b77d0bf209bf045610bc320bbe028b4f5eca17f3&temp_url_expires=1493916223' -ss 3 -s 1280x768 -f mjpeg -an -vframes 1 '/tmp/transform_c98d67799c8d.jpg' 2>&1 wgMaxShellMemory: 1048576 ffmpeg version 3.0.2-2~bpo8+1 Copyright (c) 2000-2016 the FFmpeg developers built with gcc 4.9.2 (Debian 4.9.2-10) configuration: --prefix=/usr --extra-version='2~bpo8+1' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --cc=cc --cxx=g++ --enable-gpl --enable-shared --disable-stripping --disable-decoder=libopenjpeg --disable-decoder=libschroedinger --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librubberband --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzvbi --enable-openal --enable-opengl --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-libzmq --enable-frei0r --enable-chromaprint --enable-libx264 libavutil 55. 17.103 / 55. 17.103 libavcodec 57. 24.102 / 57. 24.102 libavformat 57. 25.100 / 57. 25.100 libavdevice 57. 0.101 / 57. 0.101 libavfilter 6. 31.100 / 6. 31.100 libavresample 3. 0. 0 / 3. 0. 0 libswscale 4. 0.100 / 4. 0.100 libswresample 2. 0.101 / 2. 0.101 libpostproc 54. 0.100 / 54. 0.100 Input #0, matroska,webm, from 'http://ms-fe.svc.eqiad.wmnet/v1/AUTH_mw/wikipedia-commons-local-public.6a/6/6a/Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm?temp_url_sig=b77d0bf209bf045610bc320bbe028b4f5eca17f3&temp_url_expires=1493916223': Metadata: encoder : Lavf56.30.100 Duration: 00:04:47.58, start: 201.418000, bitrate: 1411 kb/s Stream #0:0: Video: vp8, yuv420p, 1280x768, SAR 1:1 DAR 5:3, 25 fps, 25 tbr, 1k tbn, 1k tbc (default) [swscaler @ 0x25dd4e0] deprecated pixel format used, make sure you did set range correctly Output #0, mjpeg, to '/tmp/transform_c98d67799c8d.jpg': Metadata: encoder : Lavf57.25.100 Stream #0:0: Video: mjpeg, yuvj420p(pc), 1280x768 [SAR 1:1 DAR 5:3], q=2-31, 200 kb/s, 25 fps, 25 tbn, 25 tbc (default) Metadata: encoder : Lavc57.24.102 mjpeg Side data: unknown side data type 10 (24 bytes) Stream mapping: Stream #0:0 -> #0:0 (vp8 (native) -> mjpeg (native)) Press [q] to stop, [?] for help frame= 0 fps=0.0 q=0.0 size= 0kB time=00:00:00.00 bitrate=N/A speed= 0x frame= 0 fps=0.0 q=0.0 Lsize= 0kB time=00:00:00.00 bitrate=N/A speed= 0x video:0kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown Output file is empty, nothing was encoded (check -ss / -t / -frames parameters if used)

https://upload.wikimedia.org/wikipedia/commons/thumb/6/6a/Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm/1024px--Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm.jpg

Error creating thumbnail: '/usr/bin/ffmpeg' -threads 1 -ss 140 -y -i 'http://ms-fe.svc.eqiad.wmnet/v1/AUTH_mw/wikipedia-commons-local-public.6a/6/6a/Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm?temp_url_sig=29572c53c136167ba5e6827ea5ed8e4902d1ce6c&temp_url_expires=1493916659' -ss 3 -s 1280x768 -f mjpeg -an -vframes 1 '/tmp/transform_6e40c2d1ad40.jpg' 2>&1 wgMaxShellMemory: 1048576 ffmpeg version 3.0.2-2~bpo8+1 Copyright (c) 2000-2016 the FFmpeg developers built with gcc 4.9.2 (Debian 4.9.2-10) configuration: --prefix=/usr --extra-version='2~bpo8+1' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --cc=cc --cxx=g++ --enable-gpl --enable-shared --disable-stripping --disable-decoder=libopenjpeg --disable-decoder=libschroedinger --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librubberband --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzvbi --enable-openal --enable-opengl --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-libzmq --enable-frei0r --enable-chromaprint --enable-libx264 libavutil 55. 17.103 / 55. 17.103 libavcodec 57. 24.102 / 57. 24.102 libavformat 57. 25.100 / 57. 25.100 libavdevice 57. 0.101 / 57. 0.101 libavfilter 6. 31.100 / 6. 31.100 libavresample 3. 0. 0 / 3. 0. 0 libswscale 4. 0.100 / 4. 0.100 libswresample 2. 0.101 / 2. 0.101 libpostproc 54. 0.100 / 54. 0.100 Input #0, matroska,webm, from 'http://ms-fe.svc.eqiad.wmnet/v1/AUTH_mw/wikipedia-commons-local-public.6a/6/6a/Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm?temp_url_sig=29572c53c136167ba5e6827ea5ed8e4902d1ce6c&temp_url_expires=1493916659': Metadata: encoder : Lavf56.30.100 Duration: 00:04:47.58, start: 201.418000, bitrate: 1411 kb/s Stream #0:0: Video: vp8, yuv420p, 1280x768, SAR 1:1 DAR 5:3, 25 fps, 25 tbr, 1k tbn, 1k tbc (default) [swscaler @ 0x189a4e0] deprecated pixel format used, make sure you did set range correctly Output #0, mjpeg, to '/tmp/transform_6e40c2d1ad40.jpg': Metadata: encoder : Lavf57.25.100 Stream #0:0: Video: mjpeg, yuvj420p(pc), 1280x768 [SAR 1:1 DAR 5:3], q=2-31, 200 kb/s, 25 fps, 25 tbn, 25 tbc (default) Metadata: encoder : Lavc57.24.102 mjpeg Side data: unknown side data type 10 (24 bytes) Stream mapping: Stream #0:0 -> #0:0 (vp8 (native) -> mjpeg (native)) Press [q] to stop, [?] for help frame= 0 fps=0.0 q=0.0 size= 0kB time=00:00:00.00 bitrate=N/A speed= 0x frame= 0 fps=0.0 q=0.0 Lsize= 0kB time=00:00:00.00 bitrate=N/A speed= 0x video:0kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown Output file is empty, nothing was encoded (check -ss / -t / -frames parameters if used)

See also T161465

Event Timeline

Yann created this task.May 3 2017, 4:55 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMay 3 2017, 4:55 PM
jcrespo updated the task description. (Show Details)May 3 2017, 4:56 PM
Yann updated the task description. (Show Details)May 3 2017, 5:10 PM

Does anyone know what the issue with the thumbnail is and how it can be fixed?

If a new file was transcoded and uploaded over the current version would that fix it?

brion added a subscriber: brion.May 26 2017, 6:50 PM

@Richard_Nevell_WMUK the file appears to have been trimmed or generated in a strange way: its timestamps start at ~201 seconds in, which confuses the heck out of Firefox, ffmpeg, etc. As a result, when ffmpeg skips through what it thinks is half the file, there's no video frames left to decode, and no thumbnail can be generated.

If a corrected file is uploaded over it, the new file should start generating thumbnails correctly.

$ ffprobe -show_packets Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm  | head
ffprobe version 3.3.1 Copyright (c) 2007-2017 the FFmpeg developers
  built with Apple LLVM version 8.1.0 (clang-802.0.42)
  configuration: --prefix=/usr/local/Cellar/ffmpeg/3.3.1 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvpx --enable-libx264 --enable-libxvid --enable-opencl --disable-lzma --enable-vda
  libavutil      55. 58.100 / 55. 58.100
  libavcodec     57. 89.100 / 57. 89.100
  libavformat    57. 71.100 / 57. 71.100
  libavdevice    57.  6.100 / 57.  6.100
  libavfilter     6. 82.100 /  6. 82.100
  libavresample   3.  5.  0 /  3.  5.  0
  libswscale      4.  6.100 /  4.  6.100
  libswresample   2.  7.100 /  2.  7.100
  libpostproc    54.  5.100 / 54.  5.100
Input #0, matroska,webm, from 'Templeborough_Roman_Fort_visualised_3D_flythrough_-_Rotherham.webm':
  Metadata:
    encoder         : Lavf56.30.100
  Duration: 00:04:47.58, start: 201.418000, bitrate: 1411 kb/s
    Stream #0:0: Video: vp8, yuv420p(progressive), 1280x768, SAR 1:1 DAR 5:3, 25 fps, 25 tbr, 1k tbn, 1k tbc (default)
[PACKET]
codec_type=video
stream_index=0
pts=201418
pts_time=201.418000
dts=201418
dts_time=201.418000
duration=39
duration_time=0.039000
convergence_duration=N/A
TheDJ added a subscriber: TheDJ.May 29 2017, 9:34 PM

You can easily reproduce the problem in VLC as well. Just open the file (it will say duration 4:47 minutes:seconds). Seek halfway and the file stops playing (Because there's only a minute and a half or so of video). The file was created by ffmpeg, or a tool making use of ffmpeg (note the Lavf), and for some reason it didn't write the right timecodes, or the right duration.)

I can confirm that uploading a corrected file solved the generation.

Paladox added a subscriber: Paladox.Jun 5 2017, 6:39 AM

Thanks for letting me know, I'll see what can be done about uploading a new version of the file.

brion closed this task as Resolved.Jan 20 2018, 12:18 AM
brion claimed this task.

File has been fixed; closing.