question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

boto3 1.9.199 polly synthesize_speech doesn't accept Engine parameter

See original GitHub issue

Issue

I was trying Polly neural voices. On Boto3 Polly document, synthesize_speech method already includes Engine parameter.

Screen Shot 2019-08-01 at 11 11 59 AM

However, when I used it, it complains about Unknown parameter. Unknown parameter in input: “Engine”, must be one of: LexiconNames, OutputFormat, SampleRate, SpeechMarkTypes, Text, TextType, VoiceId, LanguageCode

Steps

I tried using the following code

print('boto3 ver: ', boto3.__version__)
pollyClient = boto3.client('polly')
try:
    response = pollyClient.synthesize_speech(
                                        Engine='neural',
                                        OutputFormat='mp3',
                                        Text='test',
                                        TextType='ssml',
                                        VoiceId='Matthew'
                                    )
except Exception as e:
    print('synthesize_speech exception: ', e)
boto3 ver:  1.9.199
synthesize_speech exception:  Parameter validation failed:
Unknown parameter in input: "Engine", must be one of: LexiconNames, OutputFormat,
SampleRate, SpeechMarkTypes, Text, TextType, VoiceId, LanguageCode

Does version 1.9.199 support neural voices?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:17 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
swetashrecommented, Aug 21, 2019

I tried using virtual environment and i am not getting any error after that. These are all the steps i tried to update boto3 version in my lambda function.

python3 -m venv lambda-env
source lambda-env/bin/activate
pip install boto3
deactivate
cd lambda-env/lib/python3.7/site-packages
zip -r9 ${OLDPWD}/function.zip .
cd $OLDPWD
zip -g function.zip lambda_function.py  #lambda_function.py will contain your code 
aws lambda update-function-code --function-name function-name --zip-file fileb://function.zip

These are the steps to update boto3 version in lambda function using virtual environment.

0reactions
swetashrecommented, Nov 13, 2019

I don’t have much idea about lambda pricing but as far as i know it should not affect the cost. I am closing the issue as i believe this issue has been resolved.

Please reopen if you still have any concerns.

Read more comments on GitHub >

github_iconTop Results From Across the Web

No results found

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found