aws-solutions / media-insights-on-aws

A serverless framework to accelerate the development of applications that discover next-generation insights in your video, audio, text, and image resources by utilizing AWS Machine Learning and Media services.
Apache License 2.0
247 stars 89 forks source link

Exception 'ChaliceViewError: Exception ''Media'' #267

Closed arbahena closed 1 year ago

arbahena commented 3 years ago

Hi, I created an operator for MediaConvert that from a video input it outputs video, audio and frames from it separately. I uploaded the operator separated from the library, just uploading it to lambda and adding to it the roles and registering it via API. Then I created a workflow via API, just with one stage using the operator, till there everything was fine but when I execute the workflow I get the following error.

{
    "Code": "ChaliceViewError",
    "Message": "ChaliceViewError: Exception 'ChaliceViewError: Exception ''Media'''"
}

Hope you guys can guide me. Thanks

ianwow commented 3 years ago

I've not seen that error before but it looks like the error info is incomplete. Look for a line number in the log to indicate where the exception is being thrown then try getting more error info via print statements.

Also, try invoking your workflow with the operator disabled just to verify whether the error is with your operator or with the workflow engine.

brandold commented 3 years ago

Can you post of copy of your workflow API input?

johndpope commented 3 years ago

I tripped up on same error https://github.com/awslabs/aws-media-insights/issues/23 I basically want to derail the standard s3 bucket input and use a different one. Details in above ticket. The workflow process did kick off - and get file successfully - but then it konks out. If there's a place to look - let me know. I found the 9mb lambda process - but it's kinda black box

UPDATE (this does succeed using the recog bucket and sample.mp4 file in example / but that doesn't suit my needs) to clarify - when I setup the cloudformation - it ran with an admin user account / not iam credentials which are possible to enter during setup. rereading above - I will look for error line number - presumably in cloudwatch.

I think it might help everyone if x-ray was enabled out of the box.

Ok - so making progress / navigating into cloudwatch

CloudWatch CloudWatch Logs Log groups /aws/lambda/Recog-MediaInsightsWorkflowApi-T0KEY5QL-APIHandler-WCDS6ZY0TZC2 2020/11/18/[$LATEST]5eca9182712e473db13e344671217bf0

can see the error being thrown.

Screen Shot 2020-11-18 at 9 38 45 pm
arbahena commented 3 years ago

Thank you guys, as brandold suspected it was due to my API JSON input, I was sending it like this { "Name": "TestingMIE", "Input": { "S3Bucket": "dataplane bucket", "S3Key": "KEY", } }

brandold commented 3 years ago

Hi @arbahena,

That's good to hear, simple fix 😁

It looks like your issue is unrelated to @johndpope, despite very similar error messages. I will mark this as a bug for clarifying the exception formatting.