quicktime export to image sequence problem

I am trying to export a snapshot of a movie using QuickTime by supplying the fps of the movie.

This is the code that does the snapshot:

export document 1 to file target_file as image sequence using settings "JPEG, 10 fps"

This saves the image as PNG rather a JPEG file.

export document 1 to file target_file as image sequence using settings preset "JPEG, 25 fps"

it works fine with the preset settings. But with my custom settings it fails to create the JPEG but created a PNG instead.

I am trying to read the support docs but could not find anything.

Thanks in advance for any help!