-
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
tensorflow raises exception when importing #779
Comments
Thanks for reporting this, definitely need this to be supported. Surely related to: Miserlou/lambda-packages#31 |
Still trying to root cause this, but have narrowed it down to a problem with the |
There might be some relevant info with the following issues. At it's core. This line of code
fails from https://github.com/testing-cabal/mock/blob/master/mock/mock.py#L71, in particular, the call to https://github.com/testing-cabal/mock/search?q=semantic_version&type=Issues&utf8=%E2%9C%93 |
Well considering that all pbr is doing for mock is returning its version info I think I'm going to stop trying to figure this one out and just replace those lines of code above with some constants. I don't know enough about python packaging to effectively debug this. Work AroundReplace https://github.com/testing-cabal/mock/blob/master/mock/mock.py#L71-L73 with
A patch file is here so you can automate this. Now tensorflow runs! |
Good bug hunting! Looks like something funky is going on upstream - but where? Do you want to file related an upstream ticket for this? |
Yea I was thinking about what I could tell them, without them pointing a finger back saying what does "slim_handler" do. I'm looking at this issue which appears similar. Obviously I'd rather not patch mock every time I deploy a new tensorflow service. |
That should be easy to patch by changing the ZIP_EXCLUDES, want to send a lil' PR? :) |
Sure I can give it a shot :) |
It seems that the dist-info is already being kept in the zipfile. I'm thinking the problem is that it can't find it. I'll probably have to understand testing-cabal/mock#385 to make progress here. |
Okay. I'd also make sure that it isn't related to #755 (comment) and the related discussion on Slack w/ @mcrowson |
It's probably worth pointing out that this issue doesn't exist in python 3. I suppose since it uses the mock functionality provided by unittest. |
Work Around
#779 (comment)
Context
I'm not sure if this is a Zappa bug but since it involves tensorflow, I hope it would be of interest to others at least.
Expected Behavior
Tensorflow import without error.
Actual Behavior
Traceback:
Possible Fix
Unsure
Steps to Reproduce
app.py
settings.json
Your Environment
pip freeze
The text was updated successfully, but these errors were encountered: