def generate_thumbnail(source, outname, box, delay, fit=True, options=None):

    logger = logging.getLogger(__name__)
    tmpfile = outname + ".tmp.jpg"

    # dump an image of the video
    cmd = ['ffmpeg', '-i', source, '-an', '-r', '1',
           '-ss', delay, '-vframes', '1', '-y', tmpfile]
    logger.debug('Create thumbnail for video: %s', ' '.join(cmd))
    check_subprocess(cmd, source, outname)

    # use the generate_thumbnail function from sigal.image
    image.generate_thumbnail(tmpfile, outname, box, fit, options)
    # remove the image
    os.unlink(tmpfile)
Regression test for #10034: the hash generation function should ignore
dataset/ETHPy150Open saimn/sigal/sigal/video.py/generate_thumbnail--crossover with--dataset/ETHPy150Open AppScale/appscale/AppServer/lib/django-1.4/django/contrib/formtools/tests/__init__.py/FormHmacTests.test_textfield_hash