diff --git a/lambda-layers/DependenciesLayer/Makefile b/lambda-layers/DependenciesLayer/Makefile new file mode 100644 index 00000000..c61905d3 --- /dev/null +++ b/lambda-layers/DependenciesLayer/Makefile @@ -0,0 +1,4 @@ + +build-DependenciesLayer: + pip install --break-system-packages setuptools + pip install --upgrade -r requirements.txt --target "$(ARTIFACTS_DIR)/python/" diff --git a/pyproject.toml b/pyproject.toml index c8e647d7..0e3b1b8f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -5,7 +5,6 @@ description = " 📮 A Django port of the original PHP code from electionleaflet readme = "README.md" requires-python = ">=3.12" dependencies = [ - "aws-sam-cli==1.131.0", "aws-wsgi", "dc-design-system", "dc-django-utils", @@ -62,6 +61,7 @@ lint.extend-select = [ [dependency-groups] dev = [ + "aws-sam-cli==1.131.0", "pytest==8.3.3", "pytest-cov==6.0.0", "pytest-django==4.9.0", diff --git a/template.yaml b/template.yaml index 6c20d7be..572f3772 100644 --- a/template.yaml +++ b/template.yaml @@ -86,7 +86,7 @@ Resources: CompatibleRuntimes: - python3.12 Metadata: - BuildMethod: python3.12 + BuildMethod: makefile ElectionLeafletsFunction: diff --git a/uv.lock b/uv.lock index d782d186..0b1e3d25 100644 --- a/uv.lock +++ b/uv.lock @@ -734,7 +734,6 @@ name = "electionleaflets" version = "0.1.0" source = { virtual = "." } dependencies = [ - { name = "aws-sam-cli" }, { name = "aws-wsgi" }, { name = "dc-design-system" }, { name = "dc-django-utils" }, @@ -770,6 +769,7 @@ deploy = [ ] dev = [ { name = "aloe-django" }, + { name = "aws-sam-cli" }, { name = "django-debug-toolbar" }, { name = "moto" }, { name = "pytest" }, @@ -781,7 +781,6 @@ dev = [ [package.metadata] requires-dist = [ - { name = "aws-sam-cli", specifier = "==1.131.0" }, { name = "aws-wsgi", git = "https://github.com/DemocracyClub/awsgi.git?rev=b286f129c5580547577f942c75be74cdca707386" }, { name = "dc-design-system", git = "https://github.com/DemocracyClub/design-system.git?rev=c5c5de6b792b4b57997b65370fdcdfa4f099cdf4" }, { name = "dc-django-utils", git = "https://github.com/DemocracyClub/dc_django_utils.git?rev=7.0.1" }, @@ -817,6 +816,7 @@ deploy = [ ] dev = [ { name = "aloe-django", specifier = "==0.2.0" }, + { name = "aws-sam-cli", specifier = "==1.131.0" }, { name = "django-debug-toolbar", specifier = "==5.0.0a0" }, { name = "moto", specifier = "==5.0.21" }, { name = "pytest", specifier = "==8.3.3" },