Open jneves opened 6 years ago
I was able to solve this by cloning the repo, navigating to it in my virtual environment and using python setup.py install
. This installs it in a readable format.
There is another solution. Just remove the "-e" flag in the last line of the requirements.txt file and then reinstall the zappa package. If you have already installed zappa as editable package, you'll remove the editable package first.
having this same issue with 0.47.1 (python 3.6.5), with or without slim_handler
"dev": {
"app_function": "app.init.app",
"profile_name": "...",
"manage_roles": false,
"role_name":"...",
"role_arn": "...",
"project_name": "...",
"runtime": "python3.6",
"s3_bucket": "..."
}
Traceback (most recent call last):
File "/Users/chrisbolman/.pyenv/versions/3.6.5/lib/python3.6/site-packages/zappa/cli.py", line 2712, in handle
sys.exit(cli.handle())
File "/Users/chrisbolman/.pyenv/versions/3.6.5/lib/python3.6/site-packages/zappa/cli.py", line 509, in handle
self.dispatch_command(self.command, stage)
File "/Users/chrisbolman/.pyenv/versions/3.6.5/lib/python3.6/site-packages/zappa/cli.py", line 546, in dispatch_command
self.deploy(self.vargs['zip'])
File "/Users/chrisbolman/.pyenv/versions/3.6.5/lib/python3.6/site-packages/zappa/cli.py", line 717, in deploy
self.create_package()
File "/Users/chrisbolman/.pyenv/versions/3.6.5/lib/python3.6/site-packages/zappa/cli.py", line 2227, in create_package
disable_progress=self.disable_progress
File "/Users/chrisbolman/.pyenv/versions/3.6.5/lib/python3.6/site-packages/zappa/core.py", line 603, in create_lambda_zip
copytree(site_packages, temp_package_path, metadata=False, symlinks=False, ignore=shutil.ignore_patterns(*excludes))
File "/Users/chrisbolman/.pyenv/versions/3.6.5/lib/python3.6/site-packages/zappa/utilities.py", line 41, in copytree
lst = os.listdir(src)
FileNotFoundError: [Errno 2] No such file or directory: '/Users/chrisbolman/Dropbox/br/venv-slack/lib/python3.6/site-packages'
@ChrisBolman were you able to get it working on python 3.6 ? I am having a similar problem as yours. I've tried downgrading Zappa to 0.45.1
but didn't solve it.
@sa77 unfortunately no, by default, even upgrading to zappa 0.51.0 by default I still get PATH issue between .pyenv/versions/3.6.5/lib/python3.6/site-packages/zappa/utilities.py
and /Users/.../lib/python3.6/site-packages
(outside pyenv). reinstalling python 3.6.5, creating a new virtualenv, and/or uninstalling + reinstalling zappa don't automatically resolve.
Context
If you're trying to run a zappa as an editable from a git repo, it works, except if you have slim_handler enabled.
Expected Behavior
It should build a zip with zappa inside.
Actual Behavior
It fails with a traceback like this when building the handler_venv:
Possible Fix
Use the function for copying editables as when slim_handler is false.
Steps to Reproduce
With the following zappa_settings.json:
Run on a virtualenv:
pip install -e git+https://github.com/miserlou/zappa#egg=zappa
and thenzappa package
.Your Environment
pip freeze
:zappa_settings.py
: already above.