Skip to content
Advertisement

aws sam build not able to build packages which require paramiko due to “Error: PythonPipBuilder:ResolveDependencies”

I’ve been learning the ropes with AWS SAM and have successfully deployed a number of lambdas together with dependencies and other AWS services. However, I seem to have run into a problem when trying to deploy a lambda which relies on some specific dependencies.

Here is my requirements.txt file:

paramiko==2.4.2
cryptography==2.6.1
bcrypt==3.1.6
pynacl==1.3.0

This file is found in “packageRoot/myCodeUri/requirements.txt”

When I run sam build I get the following error:

2019-08-27 11:18:18 Running PythonPipBuilder:ResolveDependencies

Build Failed
Error: PythonPipBuilder:ResolveDependencies - {pynacl==1.3.0(wheel), cryptography==2.6.1(wheel), bcrypt==3.1.6(wheel)}

This (or at least similar) errors have been reported:here over 8 months ago but is currently not answered.

P.S. I tried this originally with just paramiko as this is the only library my script uses, as I understood; the dependencies should be automatically pulled in during the build, however this didn’t work either.

Any help would be great?

Advertisement

Answer

I’ve managed to get a workaround to build and deploy lambdas that need the paramiko library using a docker container in interactive mode. Anyone having the same problem have a look here

User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement