aws / aws/aws-lambda-base-images

AWS Lambda Runtime python3.8 missing libraries

Open
#20 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
No language data
Stars
777
Forks
118
PR merge metrics
No merged PRs in 30d

Description

I wanted to upgrade my python lambda from version 3.7 to 3.8, when I did so I ran into missing libraries, specifically

![image](https://user-images.githubusercontent.com/59868565/127460660-533e26fb-25cc-4718-8c4d-c167c7dcda09.png)

My Python lambda function makes use of **subprocess** to run shell commands. Before upgrading to 3.8 everything worked fine.

I dived deep into the issue at hand, I read that amazon linux 2 is used for runtime python3.8, so I locally created a container and tried to do what I was doing via lambda on console and things worked fine, I also created the python3.8 base image following this repo created its container and replicated the same thing and it worked fine.

It got confusing that, what worked for same runtime locally didn't work on console.

So locally I found the path for libreadline.so.6
`find / -name libreadline.so.6`

found it under /lib64 and /usr/lib64

The final thing I did was to list out the output of these directories on lambda function (running in console)

![image](https://user-images.githubusercontent.com/59868565/127462834-a981ddee-db9d-4834-84fa-53f8a969087e.png)

![image](https://user-images.githubusercontent.com/59868565/127463360-f1b96151-e6e3-4b6b-81d0-23d265c7f7bb.png)

In it's output, there was no libreadline.so.6, Now I'm fully confused that why I am experiencing this inconsistency, locally and on console.

Any comment or help would be appreciated :)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.