why is SDK Validator saying AudioTypeControl must be an associative array?

1

I'm attempting to submit a job to MediaConvert, but the validator seems to think both AudioTypeControl and LanguageCodeControl for the outputs needs to be an associative array

Here's the specific error

Found 4 errors while validating the input provided for the CreateJob operation:
\[Settings]\[OutputGroups]\[0]\[Outputs]\[0]\[AudioDescriptions]\[AudioTypeControl] must be an associative array. Found string(12) "FOLLOW_INPUT"
\[Settings]\[OutputGroups]\[0]\[Outputs]\[0]\[AudioDescriptions]\[LanguageCodeControl] must be an associative array. Found string(12) "FOLLOW_INPUT"
\[Settings]\[OutputGroups]\[0]\[Outputs]\[1]\[AudioDescriptions]\[AudioTypeControl] must be an associative array. Found string(12) "FOLLOW_INPUT"
\[Settings]\[OutputGroups]\[0]\[Outputs]\[1]\[AudioDescriptions]\[LanguageCodeControl] must be an associative array. Found string(12) "FOLLOW_INPUT"

Not sure what's going on here, I've checked my job settings against the documentation and from everything I can find, these should actually be a string, and "FOLLOW_OUTPUT" should be one of the enumerated values. Does anyone know why this error would trigger?

This is the config I'm using to create the client. (identifying values removed)

\[version] => 2017-08-29
\[endpoint] => {endpoint}
\[credentials] => Aws\Credentials\Credentials Object
(
\[key:Aws\Credentials\Credentials:private] => {key}
\[secret:Aws\Credentials\Credentials:private] => {secret}
\[token:Aws\Credentials\Credentials:private] =>
\[expires:Aws\Credentials\Credentials:private] =>
)
\[region] => us-west-2

And the Job description (Identifying values removed)

\[Inputs] => Array
(
\[0] => Array
(
\[FilterEnable] => AUTO
\[PsiControl] => USE_PSI
\[FilterStrength] => 0
\[DeblockFilter] => DISABLED
\[DenoiseFilter] => DISABLED
\[TimecodeSource] => EMBEDDED
\[VideoSelector] => Array
(
\[ColorSpace] => FOLLOW
\[Rotate] => DEGREE_0
\[AlphaBehavior] => DISCARD
)

                \\[AudioSelectors] => Array  
                    (  
                        \\[Audio Selector 1] => Array  
                            (  
                                \\[Offset] => 0  
                                \\[DefaultSelection] => DEFAULT  
                                \\[ProgramSelection] => 1  
                            )  

                    )  

                \\[FileInput] => s3://{bucket}/{path/to/input/video.mp4}  
            )  

    )  

\\[OutputGroups] => Array  
    (  
        \\[0] => Array  
            (  
                \\[Name] => FileGroupSettings Group  
                \\[OutputGroupSettings] => Array  
                    (  
                        \\[Type] => FILE_GROUP_SETTINGS  
                        \\[FileGroupSettings] => Array  
                            (  
                                \\[Destination] => s3://{bucket}/{path/to/destination/}  
                            )  

                    )  

                \\[Outputs] => Array  
                    (  
                        \\[0] => Array  
                            (  
                                \\[ContainerSettings] => Array  
                                    (  
                                        \\[Mp4Settings] => Array  
                                            (  
                                                \\[CslgAtom] => INCLUDE  
                                                \\[CttsVersion] => 0  
                                                \\[FreeSpaceBox] => EXCLUDE  
                                                \\[MoovPlacement] => PROGRESSIVE_DOWNLOAD  
                                                \\[Container] => MP4  
                                            )  

                                    )  

                                \\[VideoDescriptions] => Array  
                                    (  
                                        \\[ScalingBehavior] => DEFAULT  
                                        \\[TimecodeInsertion] => DISABLED  
                                        \\[AntiAlias] => ENABLED  
                                        \\[Sharpness] => 50  
                                        \\[AfdSignaling] => NONE  
                                        \\[DropFrameTimecode] => ENABLED  
                                        \\[RespondToAfd] => NONE  
                                        \\[ColorMetadata] => INSERT  
                                        \\[CodecSettings] => Array  
                                            (  
                                                \\[H264Settings] => Array  
                                                    (  
                                                        \\[InterlaceMode] => PROGRESSIVE  
                                                        \\[NumberReferenceFrames] => 3  
                                                        \\[Syntax] => DEFAULT  
                                                        \\[Softness] => 0  
                                                        \\[GopClosedCadence] => 1  
                                                        \\[GopSize] => 90  
                                                        \\[Slices] => 1  
                                                        \\[GopBReference] => DISABLED  
                                                        \\[SlowPal] => DISABLED  
                                                        \\[SpatialAdaptiveQuantization] => ENABLED  
                                                        \\[TemporalAdaptiveQuantization] => ENABLED  
                                                        \\[FlickerAdaptiveQuantization] => DISABLED  
                                                        \\[EntropyEncoding] => CABAC  
                                                        \\[FramerateControl] => INITIALIZE_FROM_SOURCE  
                                                        \\[RateControlMode] => QVBR  
                                                        \\[CodecProfile] => MAIN  
                                                        \\[Telecine] => NONE  
                                                        \\[MinIInterval] => 0  
                                                        \\[AdaptiveQuantization] => HIGH  
                                                        \\[CodecLevel] => AUTO  
                                                        \\[FieldEncoding] => PAFF  
                                                        \\[SceneChangeDetect] => ENABLED  
                                                        \\[QualityTuningLevel] => SINGLE_PASS  
                                                        \\[FramerateConversionAlgorithm] => DUPLICATE_DROP  
                                                        \\[UnregisteredSeiTimecode] => DISABLED  
                                                        \\[GopSizeUnits] => FRAMES  
                                                        \\[ParControl] => INITIALIZE_FROM_SOURCE  
                                                        \\[NumberBFramesBetweenReferenceFrames] => 2  
                                                        \\[RepeatPps] => DISABLED  
                                                        \\[DynamicSubGop] => STATIC  
                                                        \\[QvbrSettings] => Array  
                                                            (  
                                                                \\[QvbrQualityLevel] => 7  
                                                                \\[QvbrQualityLevelFineTune] => 0  
                                                            )  

                                                        \\[MaxBitrate] => 0  
                                                        \\[Codec] => H_264  
                                                        \\[Bitrate] => 8000000  
                                                    )  

                                            )  

                                        \\[Width] => 1920  
                                        \\[Height] => 1080  
                                    )  

                                \\[AudioDescriptions] => Array  
                                    (  
                                        \\[AudioTypeControl] => FOLLOW_INPUT  
                                        \\[LanguageCodeControl] => FOLLOW_INPUT  
                                        \\[CodecSettings] => Array  
                                            (  
                                                \\[AacSettings] => Array  
                                                    (  
                                                        \\[AudioDescriptionBroadcasterMix] => NORMAL  
                                                        \\[Bitrate] => 384000  
                                                        \\[RateControlMode] => CBR  
                                                        \\[CodecProfile] => LC  
                                                        \\[CodingMode] => CODING_MODE_2_0  
                                                        \\[RawFormat] => NONE  
                                                        \\[SampleRate] => 48000  
                                                        \\[Specification] => MPEG4  
                                                        \\[Codec] => AAC  
                                                    )  

                                            )  

                                    )  

                                \\[CaptionDescriptions] => Array  
                                    (  
                                    )  

                                \\[NameModifier] => _FHD  
                            )  

                        \\[1] => Array  
                            (  
                                \\[ContainerSettings] => Array  
                                    (  
                                        \\[Mp4Settings] => Array  
                                            (  
                                                \\[CslgAtom] => INCLUDE  
                                                \\[CttsVersion] => 0  
                                                \\[FreeSpaceBox] => EXCLUDE  
                                                \\[MoovPlacement] => PROGRESSIVE_DOWNLOAD  
                                                \\[Container] => MP4  
                                            )  

                                    )  

                                \\[VideoDescriptions] => Array  
                                    (  
                                        \\[ScalingBehavior] => DEFAULT  
                                        \\[TimecodeInsertion] => DISABLED  
                                        \\[AntiAlias] => ENABLED  
                                        \\[Sharpness] => 50  
                                        \\[AfdSignaling] => NONE  
                                        \\[DropFrameTimecode] => ENABLED  
                                        \\[RespondToAfd] => NONE  
                                        \\[ColorMetadata] => INSERT  
                                        \\[CodecSettings] => Array  
                                            (  
                                                \\[H264Settings] => Array  
                                                    (  
                                                        \\[InterlaceMode] => PROGRESSIVE  
                                                        \\[NumberReferenceFrames] => 3  
                                                        \\[Syntax] => DEFAULT  
                                                        \\[Softness] => 0  
                                                        \\[GopClosedCadence] => 1  
                                                        \\[GopSize] => 90  
                                                        \\[Slices] => 1  
                                                        \\[GopBReference] => DISABLED  
                                                        \\[SlowPal] => DISABLED  
                                                        \\[SpatialAdaptiveQuantization] => ENABLED  
                                                        \\[TemporalAdaptiveQuantization] => ENABLED  
                                                        \\[FlickerAdaptiveQuantization] => DISABLED  
                                                        \\[EntropyEncoding] => CABAC  
                                                        \\[FramerateControl] => INITIALIZE_FROM_SOURCE  
                                                        \\[RateControlMode] => QVBR  
                                                        \\[CodecProfile] => MAIN  
                                                        \\[Telecine] => NONE  
                                                        \\[MinIInterval] => 0  
                                                        \\[AdaptiveQuantization] => HIGH  
                                                        \\[CodecLevel] => AUTO  
                                                        \\[FieldEncoding] => PAFF  
                                                        \\[SceneChangeDetect] => ENABLED  
                                                        \\[QualityTuningLevel] => SINGLE_PASS  
                                                        \\[FramerateConversionAlgorithm] => DUPLICATE_DROP  
                                                        \\[UnregisteredSeiTimecode] => DISABLED  
                                                        \\[GopSizeUnits] => FRAMES  
                                                        \\[ParControl] => INITIALIZE_FROM_SOURCE  
                                                        \\[NumberBFramesBetweenReferenceFrames] => 2  
                                                        \\[RepeatPps] => DISABLED  
                                                        \\[DynamicSubGop] => STATIC  
                                                        \\[QvbrSettings] => Array  
                                                            (  
                                                                \\[QvbrQualityLevel] => 7  
                                                                \\[QvbrQualityLevelFineTune] => 0  
                                                            )  

                                                        \\[MaxBitrate] => 0  
                                                        \\[Codec] => H_264  
                                                        \\[Bitrate] => 2500000  
                                                    )  

                                            )  

                                        \\[Width] => 720  
                                        \\[Height] => 480  
                                    )  

                                \\[AudioDescriptions] => Array  
                                    (  
                                        \\[AudioTypeControl] => FOLLOW_INPUT  
                                        \\[LanguageCodeControl] => FOLLOW_INPUT  
                                        \\[CodecSettings] => Array  
                                            (  
                                                \\[AacSettings] => Array  
                                                    (  
                                                        \\[AudioDescriptionBroadcasterMix] => NORMAL  
                                                        \\[Bitrate] => 384000  
                                                        \\[RateControlMode] => CBR  
                                                        \\[CodecProfile] => LC  
                                                        \\[CodingMode] => CODING_MODE_2_0  
                                                        \\[RawFormat] => NONE  
                                                        \\[SampleRate] => 48000  
                                                        \\[Specification] => MPEG4  
                                                        \\[Codec] => AAC  
                                                    )  

                                            )  

                                    )  

                                \\[CaptionDescriptions] => Array  
                                    (  
                                    )  

                                \\[NameModifier] => _SD  
                            )  

                    )  

            )  

    )  

Edited by: SydneyMax on Feb 9, 2021 4:18 PM

Edited by: SydneyMax on Feb 9, 2021 4:18 PM

asked 3 years ago213 views
1 Answer
1

So the issue was the AudioDescriptions array item was malformed and, unlike VideoDescriptions, AudioDescriptions needs to be inside an array AudioDescriptions => \[0 => \[AudioTypeControl] => ... ]], I had it as AudioDescriptions => \[AudioTypeControl] => ...

leaving this here in case anyone trips on this

answered 3 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions