Skip to content

Commit

Permalink
Add constraint for opentelemetry
Browse files Browse the repository at this point in the history
  • Loading branch information
gjclark committed Sep 12, 2024
1 parent fa15e54 commit 97a90f1
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 5 deletions.
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,12 @@ tea-dependency-builder: build/lambda-ci.Dockerfile
@mkdir -p $(EMPTY)
@touch $@

requirements/requirements-dev.txt: requirements/requirements-dev.in requirements/requirements.txt
requirements/requirements.txt: requirements/requirements.in requirements/constraints.txt

requirements/requirements-dev.txt: \
requirements/requirements-dev.in \
requirements/constraints.txt \
requirements/requirements.txt

requirements/%.txt: requirements/%.in
$(DOCKER_DEPENDENCY_BUILDER) pip-compile -q -U --cache-dir /var/task/$(DIR)/.pip-cache/ $<
Expand Down
2 changes: 1 addition & 1 deletion cloudformation/thin-egress-app.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,7 @@ Resources:
Runtime: 'python3.8'
Layers:
- !Ref EgressLambdaDependencyLayer
- !Sub "arn:aws:lambda:${AWS::Region}:901920570463:layer:aws-otel-python38-ver-1-5-0:3"
- !Sub "arn:aws:lambda:${AWS::Region}:901920570463:layer:aws-otel-python-amd64-ver-1-25-0:1"
MemorySize: !Ref LambdaMemory

ExtDomainName:
Expand Down
3 changes: 3 additions & 0 deletions requirements/constraints.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# This needs to match the version of the otel lambda layer in cloudformation
# https://aws-otel.github.io/docs/getting-started/lambda/lambda-python#add-the-arn-of-the-lambda-layer
opentelemetry-api==1.25.0
1 change: 1 addition & 0 deletions requirements/requirements-dev.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
-c constraints.txt
-c requirements.txt
boto3
moto[awslambda]
Expand Down
8 changes: 5 additions & 3 deletions requirements/requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ exceptiongroup==1.2.2
# via pytest
idna==3.8
# via requests
importlib-metadata==8.4.0
importlib-metadata==7.1.0
# via
# build
# opentelemetry-api
Expand All @@ -64,8 +64,10 @@ markupsafe==2.1.5
# werkzeug
moto[awslambda]==5.0.14
# via -r requirements/requirements-dev.in
opentelemetry-api==1.27.0
# via opentelemetry-instrumentation
opentelemetry-api==1.25.0
# via
# -c requirements/constraints.txt
# opentelemetry-instrumentation
opentelemetry-instrumentation==0.48b0
# via -r requirements/requirements-dev.in
packaging==24.1
Expand Down
1 change: 1 addition & 0 deletions requirements/requirements.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
-c constraints.txt
cachetools
cfnresponse
chalice
Expand Down

0 comments on commit 97a90f1

Please sign in to comment.