-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
SciPy module not found #1104
Comments
I had same problem. When creating zip file for lambda, Zappa get a manylinux cached wheel file from local directory. But When Zappa reading cached wheel file, sometimes raise I don't know why exactly, But I just know wheel file was broken. So If I delete wheel file, and Re-deploy, Zappa re-downloading wheel file that is not broken. I think this line is problem. If This is clearly error. So I think in this situation, Zappa should cancel deploy(packaging) or fix this error. |
Related: #78 Which Python version are you guys using? |
@SongYunSeop - feel free to submit a PR to improve that exception! |
@Miserlou , I use Python 3.6.2 |
I have a feeling this is a P3-only bug for now. There are two bugs here: one for the zip failing (which may be an upstream problem, IDK), and one that the failure isn't halting the package deployment. |
@SongYunSeop, where did you delete the wheel file? I have deleted my folder
so zappa must be using a different cache folder... |
@Miserlou I use Python 2.7.13. OK. I will send PR! |
In my case, It is You can get this directory. import tempfile
print(tempfile.gettempdir() + "cached_wheels") |
@SongYunSeop , thanks a lot for your answer. I found that my folder was |
Ahhhhhhh. Excellent find. We could add a basic integrity check to the |
@Miserlou I send PR! |
Merged, does this address the full issue though? Should the behavior at https://github.com/Miserlou/Zappa/blob/master/zappa/core.py#L560 changed before this can be closed? |
@Miserlou The problem is that we do not know what exceptions will occur. Why not print an error message like "Please report issue on https://github.com/Miserlou/Zappa/issues/new" and exit when an unknown exception occurs? How do you think about this? |
For reference, the next bump in my adventure is #1108 |
I updated zappa after #1107 and verified that |
@Miserlou #1110 can remove some more exception. But we must fix https://github.com/Miserlou/Zappa/blob/master/zappa/core.py#L560. |
Can this be closed? |
@Miserlou , my problem was solved so I close the issue. |
I propose this issue to be reopened, it's happening again. |
Ran into the same issue, spent a while figuring out what was wrong ! Thanks a lot @alfonsomhc for the |
Unfortunately, |
Context
I have these settings:
My application requires scipy, and it is installed in the virtual environment. When I deploy my application I see this:
Expected Behavior
After
zappa deploy dev
it says "Deployment complete" in green letters, so I would expect the application to run correctly (e.g. answer curl requests correctly).Actual Behavior
If I send a curl request, I get
and the error message ends with
If I run
zappa tail
, I see this:If I undeploy, disable using precompiled packages, i.e. I set this value:
"use_precompiled_packages": false
and then redeploy, then everything works as expected, i.e. the application answers curl correctly.
This is a bit strange, because initially (two weeks ago more or less) my application required scipy (I used scikit-learn, which required numpy and scipy) and this issue was not present (i.e. I could deploy the application without including
use_precompiled_packages
in my settings (i.e. it got the default value which istrue
).However, a newer version of my application requires both scikit-learn and pandas. Therefore, I added pandas to the virtual environment. After that, the next time that I deployed I found the issue that I described.
I have tried uninstalling the packages involved and installing them again, but the issue is still there. I have tried undeploying the application and deploying it again, without any change. The only thing that seems to work is to set
use_precompiled_packages
tofalse
, but as I mentioned earlier, this was initially not necessary.The text was updated successfully, but these errors were encountered: