Uh oh!
There was an error while loading. Please reload this page.
Remove fig.packages replace with real deps. - #375
Conversation
There was a problem hiding this comment.
I noticed this was wrong. It needs to install requirements.txt first because that has pinned versions, after it can install fig itself and all deps should already be installed.
aanand
commented
Aug 5, 2014
I'm afraid we've looked at this before and it didn't work out: #264 |
dnephin
commented
Aug 5, 2014
Ok, I read over #264, but I don't see any blockers. The two issues were pyinstaller version of six and docker-py missing a tag. I've verified that pyinstaller works fine now by running both of the build scripts. Can you still reproduce the error you saw before? docker-py is well past the versions that was required, and that was never an issue in the first place because you can pin to any git sha. Managing docker-py this way means that fig users will always be behind in features and will require a lot more work from you to merge in updates and fixes. At the very least you could pin docker-py to your forked version if you have concerns with that project. |
dnephin
commented
Aug 5, 2014
It looks like the travis failure was just a connection failure downloading pyinstaller (the python 2.7 build passed). Could I bother you to re-run that build? Thanks! |
bfirsh
commented
Aug 5, 2014
We don't have a forked version – Thanks for the contribution though! Maybe we should add a readme to |
dnephin
commented
Aug 5, 2014
@bfirsh I read that argument but I don't understand it. Python packaging has come a long way in the last year, and I work with it daily without any real problems. Is there anything specific that prevents this? Also why would docker-py be such a special case? Why not vendor every dependency? It seems to be working well enough for other dependencies (and basically every other python project). I understand that Thank you for re-running the travis build. |
bfirsh
commented
Aug 5, 2014
|
bfirsh
commented
Aug 5, 2014
Besides – .dockerignore support hasn't even been released yet. If we wanted to include it, we'd have to vendor it! |
dnephin
commented
Aug 5, 2014
@bfirsh No! That's exactly what I'm trying to say, you never need to vendor it, because python packaging is awesome! It looks like I forgot to link to the docs: http://pip.readthedocs.org/en/latest/reference/pip_install.html#git I created this branch so that I could use
Pros for vendoring:
Cons for vendoring:
|
bfirsh
commented
Aug 5, 2014
Sorry @dnephin, I appreciate your enthusiasm, but we have spent a lot of time struggling with Python packaging. Referencing git tags only works with pip, and we can't guarantee that people will install using pip. The problem is pyinstaller comes with a built-in six package that it injects into the start of PYTHONPATH, so the only way to use a more recent version of six is by vendoring it. |
dnephin
commented
Aug 5, 2014
Have you considered moving away from pyinstaller? From #102 it's pretty clear pyinstaller is causing more than one issue, and there are better tools out there (https://github.com/jordansissel/fpm) Ok, if six is a blocker, I can add that back, but I still think the docker-py dependency is a win. |
bfirsh
commented
Aug 5, 2014
We have no plans to switch from a static binary, I'm afraid. We did that because we suffered so much pain from Python packaging. |
bfirsh
commented
Aug 5, 2014
We still need to vendor docker-py to be able to reference our vendored version of six. |
dnephin
commented
Aug 5, 2014
I must say that I am disappointed that you have given up on python packaging being a workable solution for managing dependencies in python. All I can say is that I have not had these problems, and that I guess I will have to maintain a fork with this support. |
dnephin
commented
Aug 14, 2014
Re-opening this issue. There is another issue it would solve (now it's both I'd also like to re-iterate that I've tested this with |
bfirsh
commented
Aug 14, 2014
@dnephin it only occurs on specific versions of OS X, if I recall correctly. We can look into removing the vendored package, but we don't have the bandwidth to battle Python packaging at the moment. If you want to help vendor the current master of docker-py, we'll gladly accept that! |
bfirsh
commented
Aug 14, 2014
To be clear, the reason I'm being stubborn about this is because our primary distribution mechanism is through shipping a binary produced by PyInstaller. It's always going to have fixed dependencies. |
dnephin
commented
Aug 14, 2014
I understand that. But from someone who doesn't use that mechanism, it's really frustrating to work with. I wish I had an OSX machine to try and reproduce the error, but I'll see if I can find anything about it in the pyinstaller source or issue tracker. This can't be a unique issue with fig. I also think that, in the long term, real packages (osxpkg, deps, rpms) are going to be quite a bit more reliable (a tool like fpm makes this easier). #102 is a good example of why I think this is the case. I know you can use dh-virtualenv for debs so that you don't have to worry about dependencies, you can just package up everything as a python virtualenv. I'm not sure if there are equivalents for osxpkg and rpms. |
dnephin
commented
Aug 14, 2014
I see pyinstaller/pyinstaller#114 is merged, but not in an official release yet. Using a git url as a requirement would still work (it is only a dev requirement). |
bfirsh
commented
Aug 14, 2014
Okay, yes, that sounds good. Now we're part of Docker we actually have the power to ship new versions of On Thu, Aug 14, 2014 at 10:57 AM, Daniel Nephin notifications@github.com
|
dnephin
commented
Aug 15, 2014
Pin to current master of |
bfirsh
commented
Aug 15, 2014
Does this mean we're still pinning versions for the build we make with PyInstaller? We definitely want to pin to specific versions for that. |
dnephin
commented
Aug 15, 2014
Yup, we install pinned requirements from |
bfirsh
commented
Aug 15, 2014
Hmm. I think in https://github.com/docker/fig/blob/master/script/build-osx |
dnephin
commented
Aug 15, 2014
Ah yes, you're right. I'll fix that |
There was a problem hiding this comment.
Could we add git to the first apt-get install so the caching works right?
There was a problem hiding this comment.
These are added separately so they are cached.
There was a problem hiding this comment.
Yep – a few versions ago, Docker started storing the hashsum of the tarball of an ADD to detect if the contents have changed. It's pretty sweet.
prologic
commented
Aug 22, 2014
+1 |
1 similar comment
satyrius
commented
Aug 22, 2014
+1 |
dnephin
commented
Aug 24, 2014
I believe I've addressed all open issues here. Let me know if there is anything else. |
bfirsh
commented
Sep 4, 2014
Great. Integration tests pass, Linux build works, OS X build works. |
bfirsh
commented
Sep 4, 2014
LGTM |
1 similar comment
aanand
commented
Sep 4, 2014
LGTM |
Signed-off-by: Daniel Nephin <dnephin@gmail.com>
03c9639 to
4d0f52bComparednephin
commented
Sep 5, 2014
rebased with master to resolve merge conflicts |
bfirsh
commented
Sep 5, 2014
@dnephin D'oh. Needs another rebase. |
bfirsh
commented
Sep 5, 2014
Tell you what I'll do it for you. |
bfirsh
commented
Sep 5, 2014
Thanks for your help with this @dnephin! Glad we got there in the end :D |
thaJeztah
commented
Sep 5, 2014
Happy to see this merged as well, and a big thank you @dnephin for being persistent 😺 |
Closesdocker#375 Signed-off-by: Yuval Kohavi <yuval.kohavi@gmail.com>
api/shim: fix indent
This change will allow users to install the latest
docker-pywhich adds.dockerignoresupport.It is also much easier to manage dependencies with a version, instead of trying to merge in patches from another repo.
If someone needs to run the latest
docker-py(as I do), pip supports git urls (http://pip.readthedocs.org/en/latest/reference/pip_install.html#git), so you can set a requirement of the master branch. This also lets you run your against your own fork if the upstream is slow to merge in PRs.I've verified that
script/build-linux, andscript/build-osxstill works (as well as the test suite). Let me know if there are any other tests I should run.