Skip to content

Commit

Permalink
Update pip to python -m pip to fix pip install warning in SAM bui…
Browse files Browse the repository at this point in the history
…ld (open-telemetry#81)

* bump python sdk to 1.10/0.20b0

* add lambda resource attributes by env variable

* change Lambda function span kind to server

* bump collector to 0.25

* panic

* update pip to pythong -m pip, fix pip install warning
  • Loading branch information
wangzlei authored Apr 27, 2021
1 parent abf5c2e commit a1bda23
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion python/sample-apps/build.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/sh

mkdir -p build/python
pip3 install -r function/requirements.txt -t build/python
python3 -m pip install -r function/requirements.txt -t build/python
cp function/lambda_function.py -t build/python
cd build/python || exit
zip -r ../function.zip *
4 changes: 2 additions & 2 deletions python/src/otel/Dockerfile
Original file line number Diff line number Diff line change
@@ -7,8 +7,8 @@ ADD . /workspace
WORKDIR /workspace

RUN mkdir -p /build && \
pip3 install -r otel_sdk/requirements.txt -t /build/python && \
pip3 install -r otel_sdk/requirements-nodeps.txt -t /build/tmp --no-deps && \
python3 -m pip install -r otel_sdk/requirements.txt -t /build/python && \
python3 -m pip install -r otel_sdk/requirements-nodeps.txt -t /build/tmp --no-deps && \
cp -r /build/tmp/* /build/python/ && \
rm -rf /build/tmp && \
cp -r otel_sdk/* /build/python && \
4 changes: 2 additions & 2 deletions python/src/otel/Makefile
Original file line number Diff line number Diff line change
@@ -11,8 +11,8 @@ LDFLAGS=-ldflags "-s -w -X $(BUILD_INFO_IMPORT_PATH).GitHash=$(GIT_SHA) -X $(BUI

build-OTelLayer:
mkdir -p $(ARTIFACTS_DIR)/python
pip3 install -r $(SDK)/requirements.txt -t $(ARTIFACTS_DIR)/python
pip3 install -r $(SDK)/requirements-nodeps.txt -t $(ARTIFACTS_DIR)/tmp --no-deps
python3 -m pip install -r $(SDK)/requirements.txt -t $(ARTIFACTS_DIR)/python
python3 -m pip install -r $(SDK)/requirements-nodeps.txt -t $(ARTIFACTS_DIR)/tmp --no-deps
cp -r $(ARTIFACTS_DIR)/tmp/* $(ARTIFACTS_DIR)/python/
rm -rf $(ARTIFACTS_DIR)/tmp
cp -r $(SDK)/* $(ARTIFACTS_DIR)/python

0 comments on commit a1bda23

Please sign in to comment.