Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update python version references from 3.9 to 3.11 #1341

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions content/en/getting-started/quickstart/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ An internal SES LocalStack testing endpoint (`/_localstack/aws/ses`) is configur
- [LocalStack CLI](https://docs.localstack.cloud/getting-started/installation/#localstack-cli)
- [LocalStack Web Application account](https://app.localstack.cloud/sign-up) & [Auth Token](https://docs.localstack.cloud/getting-started/auth-token/)
- [Docker](https://docs.docker.com/get-docker/)
- [Python 3.9+](https://www.python.org/downloads/) & `pip`
- [Python 3.11+](https://www.python.org/downloads/) & `pip`
- [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html) & [`awslocal` wrapper](https://docs.localstack.cloud/user-guide/integrations/aws-cli/#localstack-aws-cli-awslocal)
- `jq`, `zip` & `curl`

Expand Down Expand Up @@ -90,10 +90,10 @@ pip install -r requirements-dev.txt
{{< /tabpane >}}

{{< callout "tip" >}}
If you are encountering issues with the installation of the packages, such as Pillow, ensure you use the same version as the Python Lambdas (3.9) for Pillow to work. If you're using <a href="https://github.com/pyenv/pyenv">pyenv</a>, install and activate Python 3.9 with the following commands:
If you are encountering issues with the installation of the packages, such as Pillow, ensure you use the same version as the Python Lambdas (3.11.6) for Pillow to work. If you're using <a href="https://github.com/pyenv/pyenv">pyenv</a>, install and activate Python 3.11 with the following commands:
{{< command >}}
$ pyenv install 3.9.0
$ pyenv global 3.9.0
$ pyenv install 3.11
$ pyenv global 3.11
{{< / command >}}
{{< /callout >}}

Expand Down Expand Up @@ -154,7 +154,7 @@ $ awslocal sns subscribe \
$ (cd lambdas/presign; rm -f lambda.zip; zip lambda.zip handler.py)
$ awslocal lambda create-function \
--function-name presign \
--runtime python3.9 \
--runtime python3.11 \
--timeout 10 \
--zip-file fileb://lambdas/presign/lambda.zip \
--handler handler.handler \
Expand All @@ -174,7 +174,7 @@ $ awslocal lambda create-function \
--function-name list \
--handler handler.handler \
--zip-file fileb://lambdas/list/lambda.zip \
--runtime python3.9 \
--runtime python3.11 \
--timeout 10 \
--role arn:aws:iam::000000000000:role/lambda-role \
--environment Variables="{STAGE=local}"
Expand All @@ -190,7 +190,7 @@ $ awslocal lambda create-function-url-config \
{{< tab header="macOS" lang="shell" >}}
cd lambdas/resize
rm -rf libs lambda.zip
docker run --platform linux/x86_64 -v "$PWD":/var/task "public.ecr.aws/sam/build-python3.9" /bin/sh -c "pip install -r requirements.txt -t libs; exit"
docker run --platform linux/x86_64 -v "$PWD":/var/task "public.ecr.aws/sam/build-python3.11" /bin/sh -c "pip install -r requirements.txt -t libs; exit"
cd libs && zip -r ../lambda.zip . && cd ..
zip lambda.zip handler.py
rm -rf libs
Expand All @@ -200,7 +200,7 @@ cd ../..
cd lambdas/resize
rm -rf package lambda.zip
mkdir package
pip install -r requirements.txt -t package --platform manylinux_2_28_x86_64 --python-version 3.9 --no-deps
pip install -r requirements.txt -t package --platform manylinux_2_28_x86_64 --python-version 3.11 --no-deps
zip lambda.zip handler.py
cd package
zip -r ../lambda.zip *;
Expand All @@ -223,7 +223,7 @@ cd ../..
{{< command >}}
$ awslocal lambda create-function \
--function-name resize \
--runtime python3.9 \
--runtime python3.11 \
--timeout 10 \
--zip-file fileb://lambdas/resize/lambda.zip \
--handler handler.handler \
Expand Down