by DividableMiddle · 7y ago · 0 comments
Compare that to "brew install python". Now you have the most up to date version, with the right permissions for your user, that you can always brew uninstall and reinstall later if you need a different version or a clean install.
That is the wrong way to do it. Just install pyenv/pipenv to manage different Python versions. It's dead simple to maintain system Python, Python 2.7x, and Python3.7.3 that way.
otoh, pointing people towards messing with system python... well, it's a trap. And they will get burned, and it will be a nightmare to straighten out.
The alternatuve to the current decision is for apple to assign people to keep updating python and provide previous versions as packages like linux distrib does. But it has never been the way they do business.
I definitely understand that the installation process for things like python can be confusing to non-programmers, but I think this is a bit disingenuous. You don't have to learn a build system to install it; python was the first programming language I ever learned, and I used it years before I ever even had any idea what a build system is.
If you can't even download an installer and run it, then yeah, maybe not quite ready for programming either.
Please forgive my snark, but this would be exactly my thought process as a reasonably competent computer user who wanted to learn Python.
it's not like installing python is any more complicated than any other piece of software that needs to be installed. Windows users have had no choice but to do that for decades.
You're saying this like it's a good thing.
The problem is doing something simple, like an installer. bash => zsh: fine. You can still install with the old /bin/bash. but for many cases a shell is not enough, and then you have to compile something statically for a trivial dynamic task. Which makes the download 10x larger. Not cool.
What do you mean?
When you build and package things for production you should create an environment. This ensures the packaging the right versioning of requirements for build.
Say you build using the system version but use packages based on another version. It may work for you but probably won’t work elsewhere.
The problem comes about when someone does the following:
- creates python project
- pip install some_package
- import some_package
Turns out some package was already in the path but a different version
- proceeds to test and build with the assumption of some_package @ newer
- all tests pass
- ships project with requirements of some_package @ newer
Someone attempts to use the package but it doesn’t work.
https://developer.apple.com/documentation/hypervisor https://github.com/moby/hyperkit
Further, there's no decent solution for shipping a macOS container image to run in a VM. Linux, yes, Mac, no.
Finally, good luck getting your virtualized macOS app to interact reasonably with your main OS (no drag and drop, no OpenGL, etc.).
I would rather chroot.
Does anyone actually use Docker on Mac?
Xhyve is more of a proof-of-concept than a production-ready tool.
What? We use it at work every day for local development, and my previous employer did as well. It has issues, definitely, but they have more to do with Docker than with xhyve.
I use it extensively. It is a desktop product however; it you aren't expected to put a swarm of MacBook pros into production.
Calling it “not serious” is quite wrong.
Sure, for development tasks.
All the interesting container stuff is on other platforms.
It might be out of fear, maybe because apple doesn't want macos to be virtualized.
It would be really nice to have say the current xcode in one container and a dev xcode in another. It would be nice to farm work out to a lot of machines.
or a dockerfile like: FROM macos:10.14
RUN installer xcode... RUN xcode-build myproject
Given that Apple is (or at least was) one of the biggest users of Mesos in the world and have invited me to interview specifically on the back of the operationalization of containers, I'm guessing that the staggeringly bright programmers they've got probably understand containers.
Just a little hunch, you know?
Maybe it's another "you're not the target market" kind of thing.
The point I'm getting at is that folks on other platforms have lots and lots of options and apple doesn't provide any.
The macOS EULA explicitly allows macOS to be virtualized if you do it on a Mac running macOS.
> It would be really nice to have say the current xcode in one container and a dev xcode in another.
This is the entire point behind xcode-select. I currently have Xcode-beta and Xcode on side-by-side on my machine, and they pretty much coexist.
- I think xcode-select just modifies a .plist.
They do offer a set of "primitives" for virtualization, which can be hooked into by third-party solutions like Docker if they want to do so.