Your Environment Information --------------------------- Operating System: linux Node Version: 12.21.0 Framework Version: 2.56.0 (local) Plugin Version: 5.4.4 SDK Version: 4.3.0 Components Version: 3.16.0
Print out from codebuild console:
Serverless: Generated requirements from /codebuild/output/src517191577/src/xxx/xxx/FactoryResetLF/requirements.txt in /codebuild/output/src517191577/src/xxx/xxx/FactoryResetLF/.serverless/requirements.txt... Serverless: Installing requirements from /root/.cache/serverless-python-requirements/01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b_slspyc/requirements.txt ... Serverless: Using download cache directory /root/.cache/serverless-python-requirements/downloadCacheslspyc
Added list to buildspec to make sure it was inside the environment before running sls deploy
total 284K -rw-r--r-- 1 root root 5.1K Aug 26 19:43 baseline.yml -rw-r--r-- 1 root root 2.7K Aug 26 19:43 buildspec.yaml drwxr-xr-x 5 root root 4.0K Aug 26 19:44 env drwxr-xr-x 471 root root 20K Aug 26 19:45 node_modules -rw-r--r-- 1 root root 219K Aug 26 19:45 package-lock.json -rw-r--r-- 1 root root 0 Aug 26 19:44 requirements.txt -rw-r--r-- 1 root root 23K Aug 26 19:43 serverless.yml drwxr-xr-x 7 root root 4.0K Aug 26 19:43 src
Anyone else seeing this issue? I have tried creating my virtual environment with requirements.txt on-build as well as trying to change permissions on source directory (forgot codebuild only has root). Also tried updating python to 3.17 and updating pip along with pip packages and yum apps.
I am using the python requirements plugin with the default packaging and have tried defining the requirements file name for the plugin. Also ensured usePipenv is set to true.
On the other hand, should I not be worried about the error? I know it is not best practice. But it is building the requirements file and I am only importing a single library for use in my lambda package.