0

I am having an issue creating a AWS Lambda function programmatically. The error I get is

botocore.exceptions.ParamValidationError: Parameter validation failed: Unknown parameter in input: "RunTime", must be one of: FunctionName, Runtime, Role, Handler, Code, Description, Timeout, MemorySize, Publish, VpcConfig, PackageType, DeadLetterConfig, Environment, KMSKeyArn, TracingConfig, Tags, Layers, FileSystemConfigs, ImageConfig, CodeSigningConfigArn, Architectures, EphemeralStorage

After a bit of research I found this AWS page(https://aws.amazon.com/premiumsupport/knowledge-center/lambda-python-runtime-errors/) that suggests that I needed to upgrade boto3 and botocore, which I did to the latest version as shown in my pip list.

Package               Version
--------------------- ---------
awscli                1.25.8
boto                  2.49.0
boto3                 1.24.8
botocore              1.27.8

However, there is a mismatch when I run the script locally and with the following commands:

print(boto3.__version__)
print("botocore version:"+botocore.__version__)

1.24.4
botocore version:1.27.4

How do I force my script to run the latest version of boto3/botocore, assuming that is the reason I can't create the Lambda function in code.

2
  • 1
    Is this more a simple typo: Runtime vs RunTime? Commented Jun 14, 2022 at 17:16
  • That was it cant believe I missed that. Thanks. Commented Jun 14, 2022 at 20:09

1 Answer 1

2

The Lambda developer guide gives instructions on how to package your Python function, including details on how to zip up dependencies.

Sign up to request clarification or add additional context in comments.

2 Comments

This seems to be a solution to a different problem.
There's an KB article for the same error in my OP, so its still relevant IMO since it involves managing dependencies. Just turned out in this case it was a typo.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.