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

Upgrade Lambda runtime to Python 3.11 #60

Merged
merged 1 commit into from
Mar 5, 2024
Merged
Show file tree
Hide file tree
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
4 changes: 2 additions & 2 deletions .github/workflows/deploy-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ jobs:

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9
- name: Set up Python 3.11
uses: actions/setup-python@v2
with:
python-version: 3.9
python-version: '3.11'
- name: Install Python dependencies
run: pip install tox
- name: Test with tox
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/deploy-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ jobs:

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9
- name: Set up Python 3.11
uses: actions/setup-python@v2
with:
python-version: 3.9
python-version: '3.11'
- name: Install Python dependencies
run: pip install tox
- name: Test with tox
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pr-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ jobs:

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9
- name: Set up Python 3.11
uses: actions/setup-python@v2
with:
python-version: 3.9
python-version: '3.11'
- name: Install dependencies
run: pip install tox
- name: Test with tox
Expand Down
4,753 changes: 3,746 additions & 1,007 deletions package-lock.json

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
"description": "Data exporter",
"author": "",
"devDependencies": {
"@kakkuk/serverless-aws-apigateway-documentation": "1.1.12",
"serverless": "^3.21.0",
"serverless-better-credentials": "^1.2.1",
"@kakkuk/serverless-aws-apigateway-documentation": "^1.3.0",
"serverless": "^3.38.0",
"serverless-better-credentials": "^2.0.0",
"serverless-plugin-git-variables": "^5.2.0",
"serverless-prune-plugin": "^2.0.1",
"serverless-python-requirements": "^5.4.0"
"serverless-prune-plugin": "^2.0.2",
"serverless-python-requirements": "^6.0.1"
}
}
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tool.black]
target-version = ['py39']
target-version = ['py311']
# Keep exclude in sync with flake8 config in tox.ini
exclude = '''
/(
Expand Down
29 changes: 16 additions & 13 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
#
# This file is autogenerated by pip-compile with python 3.9
# To update, run:
# This file is autogenerated by pip-compile with Python 3.11
# by the following command:
#
# pip-compile
#
anyio==3.6.1
# via starlette
attrs==21.4.0
# via jsonschema
aws-xray-sdk==2.10.0
aws-xray-sdk==2.12.1
# via okdata-data-exporter (setup.py)
boto3==1.24.21
# via okdata-data-exporter (setup.py)
botocore==1.27.21
boto3==1.34.51
# via
# okdata-aws
# okdata-data-exporter (setup.py)
botocore==1.34.51
# via
# aws-xray-sdk
# boto3
Expand All @@ -33,11 +35,11 @@ jmespath==1.0.1
# botocore
jsonschema==4.6.1
# via okdata-sdk
okdata-aws==1.0.0
okdata-aws==2.1.0
# via okdata-data-exporter (setup.py)
okdata-resource-auth==0.1.4
# via okdata-data-exporter (setup.py)
okdata-sdk==2.1.0
okdata-sdk==3.1.0
# via okdata-aws
pyasn1==0.4.8
# via
Expand Down Expand Up @@ -66,7 +68,7 @@ requests==2.31.0
# python-keycloak
rsa==4.8
# via python-jose
s3transfer==0.6.0
s3transfer==0.10.0
# via boto3
six==1.16.0
# via
Expand All @@ -79,13 +81,14 @@ starlette==0.36.2
structlog==21.5.0
# via okdata-aws
typing-extensions==4.2.0
# via
# pydantic
# starlette
# via pydantic
urllib3==1.26.18
# via
# botocore
# okdata-sdk
# python-keycloak
# requests
wrapt==1.14.1
# via aws-xray-sdk
# via
# aws-xray-sdk
# okdata-data-exporter (setup.py)
4 changes: 2 additions & 2 deletions serverless.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
frameworkVersion: ">=3.21.0 <4.0.0"
frameworkVersion: ">=3.38.0 <4.0.0"

service: data-exporter

provider:
name: aws
runtime: python3.9
runtime: python3.11
region: ${opt:region, 'eu-west-1'}
endpointType: REGIONAL
stage: ${opt:stage, 'dev'}
Expand Down
9 changes: 6 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,13 @@
url="https://github.com/oslokommune/okdata-data-exporter",
packages=setuptools.find_packages(),
install_requires=[
"aws-xray-sdk",
"boto3",
"okdata-aws",
"aws-xray-sdk>=2.12,<3",
"boto3>=1.28.11",
"okdata-aws>=2,<3",
"okdata-resource-auth",
"requests",
# Not used directly, it's a transitive dependency from `aws-xray-sdk`,
# but we need version 1.14 or above to make it work with Python 3.11.
"wrapt>=1.14,<2",
],
)
5 changes: 1 addition & 4 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
[tox]
envlist = py39,flake8,black
envlist = py311,flake8,black

[testenv]
install_command =
pip install --extra-index-url={env:extra_index_url:https://artifacts.oslo.kommune.no/repository/itas-pypip/simple} {opts} {packages}

# FIXME (2020-11-19): responses locked to 0.12.0 as 0.12.1 conflicts with moto
deps=
pytest
Expand Down
Loading