[英]AWS Elastic Transcoder Create Job Error
Does anyone know why I keep getting this error: 有谁知道为什么我不断收到这个错误:
JSONResponseError: 400 Bad Request
{u'Message': u'Start of list found where not expected'}
It was working fine when I used the output dictionary specified in the api, but when I since I switched to the outputs list of dicts, I've been getting the aforementioned error. 当我使用api中指定的输出字典时,它运行良好,但是自从切换到字典的输出列表后,我遇到了上述错误。
Here's the code I wrote: 这是我写的代码:
transInput = {
'Key': path,
'FrameRate': 'auto',
'Resolution': 'auto',
'AspectRatio': 'auto',
'Interlaced': 'auto',
'Container': 'auto'
}
pprint (transInput)
#Create a job for each desired preset
for pId, descrip in presets.iteritems():
transOutput = {
'PresetId': pId,
'Rotate': 0,
'ThumbnailPattern': 00001,
'Key': path +"-" + descrip
}
outputs.append(transOutput)
try:
transcode.create_job(pipelineId, transInput, outputs)
except Exception, e:
print e
如果要使用输出列表,则必须将其指定为outputs
参数:
transcode.create_job(pipelineId, transInput, outputs=output)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.