Bug: sam build - ReadTimeout
Description:
Error: UnixHTTPConnectionPool(host='localhost', port=None): Read timed out. (read timeout=60) when running sam build
Steps to reproduce:
I have a SAM stack with several Lambdas (Python), one of them seems to have quite heavy list of dependencies. sam build fails with the mentioned error the build inside container was successful according to log
Observed result:
Expected result:
I expect successful result of sam build
Additional environment details (Ex: Windows, Mac, Amazon Linux etc)
{
"version": "1.146.0",
"system": {
"python": "3.11.10",
"os": "Linux-6.11.0-1018-azure-x86_64-with-glibc2.39"
},
"additional_dependencies": {
"container_engine": "Docker(v28.0.4)",
"aws_cdk": "Not available",
"terraform": "Not available"
},
"available_beta_feature_env_vars": [
"SAM_CLI_BETA_FEATURES",
"SAM_CLI_BETA_BUILD_PERFORMANCE",
"SAM_CLI_BETA_TERRAFORM_SUPPORT",
"SAM_CLI_BETA_PACKAGE_PERFORMANCE",
"SAM_CLI_BETA_RUST_CARGO_LAMBDA"
]
}
The 60 second time limit is coming from the docker.py library that SAM CLI depend on. It weird that it takes more than a minutes to return the result.
Do you have a example project that we can use to reproduce the issue? This seems to be a performance issue rather than a bug.
Not anymore, unfortunately. But it was some Python project with docling and it was building for quite a while