-
-
Notifications
You must be signed in to change notification settings - Fork 641
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
python_awslambda zip doesn't include 3rd party dependencies #15239
Comments
@ricucho the complete platform data needs to represent the target platform, which is an AWS lambda machine / Linux. So one thing to correct is the content of the complete platform JSON by running the same commands you did to get the Mac complete platform data, but this time on an AWS Lambda equivalent host or image. |
Below is the platform file for the lambda:
|
This issue was fixed by adding the platform files for both Mac and Lambda (see previous comments for the content of these files). Below is the resulting BUILD.bazel:
|
Describe the bug
The Lambda zip generated by the
python_awslambda
doesn't have the third-party dependencies defined in the project'srequirements.txt
. Furthermore, when I try to unzip it locally, I get the following error:Unable to expand "lambda.zip". It is in an unsupported format
.pants.toml (project/pants.toml)
requirements.txt (project/requirements.txt)
Lambda Function (project/appcode/api/transaction_details/src/main.py)
BUILD File (project/appcode/api/transaction_details/src/BUILD)
complete_platforms.json (project/appcode/api/transaction_details/src/complete_platforms.json)
Pants version
2.10.0
OS
Mac (Monterrey - 12.3.1)
Additional info
Slack discussion: https://pantsbuild.slack.com/archives/C046T6T9U/p1650655491931529
The text was updated successfully, but these errors were encountered: