Fedora Loves Python
fedoralovespython.org
fedoralovespython.org
Two lines below:
> However, /usr/bin/python remains Python 2, [...]
Not sure what they call "default". They seem to quote some PEP that only specified that this was okay during a transition period. I think we're WAY past that. If not, then the first statement is plainly wrong.
> The more general python command should be installed whenever any version of Python 2 is installed and should invoke the same version of Python as the python2 command
Rather than permitting python to refer to python2 during a transition period, that is the recommendation. They later state
> It is anticipated that there will eventually come a time where the third party ecosystem surrounding Python 3 is sufficiently mature for this recommendation to be updated to suggest that the python symlink refer to python3 rather than python2.
PEP394 actually states the "recommendation will be periodically reviewed over the next few years, and updated when the core development team judges it appropriate.". You might think we are way past that, but it seems they don't.
Given a default Fedora install does not have the python command but does have python3, I'd say it's 3.x by default.
https://developer.fedoraproject.org/tech/languages/python/mu...
- iirc they can only go down one version (i.e. 3.4/3.5, no 3.4.1/3.4.2)
- it's always been a real b@llache to install newer versions on Debian releases where it has not been officially packaged (e.g. 3.6 on jessie). With most packages, you can grab the source from Sid and rebuild it on Stable; with Python it's become basically impossible, the pile of dependencies below and above the package is unwieldy. And this despite tons of policies around packaging python apps, which was supposed to make it easier to run multiple versions.
If Fedora really made things easier in this area, it's most welcome. However, when a marketing page starts with "you can now do this standard thing that actually most people have been doing for years already" (-m venv), I'm somewhat skeptical.
That said, I think debian users should lean heavily on the apt versions of any python modules. I will usually install as many modules with apt as possible and then use `python3 -m venv --system-site-packages` to have access to them. That way there are usually very few packages I need to compile/install myself. Seems like a pretty good balance.
pip is another beast: it's not included in the stdlib, but installed when you install Python with the ensurepip script. Debian just don't run the script.
Does fedora increases my productivity?
Late 2015 I decided I wanted a "Chromebook" style user experience where I could have a repeatable build of the base OS that could be thrown away plus a backup system based around duplicity to restore my homedir. I had used preseed to deploy large fleets of Ubuntu boxes at work so it was a natural option. But I decided a few things: Firstly, I was sick of LTS 3.x kernel. Secondly, if 16.04 and all other distros were adopting systemd I may as well go to the source and use a RH based distro. Finally, that preseed wasn't as good as Kickstart used in RH based distros.
So I came up with https://github.com/sinner-/kickstart-fedora-workstation to provide repeatable builds of Fedora the way that I like it. I've been happily using it since then (across 2 versions of Fedora and a hard drive failure)! The .ks file will be updated for F26 this weekend as it just went GA today.
Why would you use it over Ubuntu? Ubuntu has an important advantage over all other distros. When you try to install some not-so-common program that is not in the official repositories, usually the linux instructions assume that you are using Ubuntu. For an experienced user it's not really that important but for a novice it certainly is. Now, Ubuntu had some negative publicity with regards to the [amazon unity search](https://en.wikipedia.org/wiki/Unity_%28user_interface%29#Pri...) and Shuttleworth's response ["we have root"](https://security.stackexchange.com/questions/44512/what-does...). On the other hand Fedora, although sponsored by Red Hat, respects the community, so fortunately there were no incidents like that. Ubuntu also had Unity which users either loved or hated, while other distros focused on either Gnome or KDE.
On servers the options are more or less grouped. So, you should first chose between the group of Debian/Ubuntu, Fedora/Centos/RHEL, etc. Once you chose the group then you can chose the distro itself. The fact that I used Fedora on the desktop for so long made the choice of Fedora on the server much easier.
Finally, will Fedora increase your productivity? No, not really. Your setup will increase your productivity. Choices like using KDE or Gnome, or the setup of (keyboard) shortcuts to meet your needs matter. I hope this helps, have fun!
Not everything is black and white, and while Ubuntu has failed in some aspects, it succeeded in others. Also, they are not hesitant to admit a failure, upstart is a thing of the past with Ubuntu using systemd, unity and "their phone thing" are being discontinued with focus shifting to the Gnome desktop and the traditional PC/Laptop/server market.
If you consider pulseaudio, systemd and not being able to play mp3 traditional. Also, they used to fuck with encryption in some way, not sure if they still do it.
In the end, do you trust more Poettering or Debian or Ubuntu developers?
Only a little sarcastic; RHEL and Red Hat's historic treatment of CentOS had a lot of echos of Oracle's treatment of similar projects. They've gotten a little better in some regards (now own CentOS and seem to care about it) and worse in others (the of marketing and politics instead of merit).
What? Red Hat didn't treat CentOS badly: they happily let people make trademark-less respins of their OS per the license and didn't try and stop anyone from doing so.
(Disclaimer: worked for RH around 2003-6)
Obviously Yggdrasil isn't using systemd and that doesn't change anything.
In the end I stuck with Fedora because I preferred GNOME over Unity, and because it would let me try Wayland before any other distro... I like the "consumer focused bleeding edge" that Fedora offers.
- You don't have to configure everything from scratch
- Packages are kept relatively up to date
It's not rolling release (unless you use Rawhide) but software is recent enough for it to be a non-issue.It's also an extremely well-established project with a huge software repository.
It would take me 30 minutes to build an Arch the way I wanted it. The install on Ubuntu already took 2 hours, then I would have to spend countless hours uninstalling trash I didn't want.
Maybe this isn't true anymore, but "apt-get [package]" was a game of whack-a-mole. If I ran apt-get, I wanted the latest version, not have to guess, hunt, uninstall wrong versions, etc.
Fedora is a minimal system, very much like I would have on Arch. dnf defaults to the most recent stable version of whatever I want to use, and the entire system is built with that in mind.
It sort of depends on what kind of programs you prefer to use. I personally like to have the most recent "x," though I understand the arguments for not having that preference. However, knowing the default is going to be the most recent, I have no need to think beyond that simple fact if I need to use an older version of a program.
Fedora, as a rolling distro, is not particularly suitable for (production) servers. You'd use CentOS for that, to keep familiar RedHat-family tooling.
Of course, Debian gives you both checkpoint ('stable') and rolling ('unstable'), so you can use the same thing on both server and workstation. :) Debian's not as warty as it used to be (I came to linux via ubuntu, and have been switching to debian on workstations + servers over the past couple of years)
EDIT: correction, Fedora is a checkpoint distro, but it doesn't support for long. IIRC it has 6-monthly releases with 12 months of support, whereas Ubuntu has 6-monthly with 18 months of support, and every 24 months you get a 5-year version. Basically Fedora needs to be upgraded twice a year, which isn't suitable for (production) servers.
Don't knock it until you try it.
Anyway, after years of using different distros (mainly the Debian and Ubuntu family of things and Arch) on different boxes I tried the Fedora KDE spin on my main desktop - mainly because the out of the box KDE 4 experience had been a bit underwhelming on various distros and I got tired of accidentally breaking stuff on Arch due to applying some careless updates. For me Fedora offers the optimum when it comes to the balance between stability and bleeding edge and the availability of packages. Rarely when things break they also get fixed promptly, third party rpms and repos are pretty decent and it's popular enough that even some proprietary stuff (mainly Steam and Sublime Text in my case) are easy to run and well supported. Really excited also to try out Wayland with Plasma soon. For a development box it has been a good choice, lot of the experience applies well also to RHEL and CentOS servers and doesn't suffer from weird decisions by the project maintenance.
I haven't seen a single Fedora install in all my years on a desktop or server.
For one, Fedora is the open, no contract, version. And yes, tons of people use it, including on the desktop.
Second, even for the "enterprise" version, tons of businesses use Centos, which is kind of like RHEL with no contract. It's immensely popular.
I have tons of experience with all the major distros and Fedora is my pick for desktop use. I don't work somewhere with an RH contract, I just like it. There are other good desktop distros but Fedora suits me. It's a good blend of cutting edge and stability, it has very good docs, has a large community, and it is 100% open source (I can still choose to install proprietary stuff if I need a driver or something, and there are usually already rpms in a repo for it if I do).
So, "hi", you've now met someone who uses Fedora willingly (enthusiastically, even).
On the other hand, ubuntu /debian packages are well organized at this point.
For the operating system, sure, use the OS packages.
For writing and deploying an application in a language? Never use the OS packages; manage it using the language's tools. My Python applications deploy into a virtualenv and install their dependencies using pip.
No. Never. Not for any reason, ever. Never.
The language's packaging ecosystem and toolchain are:
* Tailored to the language, not the operating system, which means they're reproducible on multiple operating systems. This is important, since your developers are not running RHEL server as their laptop OS, and as a result they'll be using the language toolchain regardless of what your "sysadmin" does to the production environment.
* More likely to be up-to-date and/or update-able than distro-format packages. Unless you want to be running two years ago's version of your libraries (or older), the only way you'll get distro-format packages is to build them yourself... which requires you to go grab them from the language's package system, since that's where they get published, and maintain your own pipeline to re-package them into the distro format. Now you've injected additional moving parts into your systems where none were needed.
Distro packages are only for the base operating system and things like your HTTP daemon. For application code and dependencies, the distro packages should only be involved insofar as they bootstrap you to the point of being able to use the language's toolchain. Insisting on distro-format packages for the whole thing is the path to overcomplex builds/deploys and difficult-to-update codebases.
because otherwise nobody will know where it's deployed or what its dependencies are or whether they're up to date
I can, at a glance, look at any application in production where I work and see what its full dependency tree is and whether those dependencies are up-to-date (and if not, whether they're just outdated or also subject to security advisories). Using things built on the language toolchain. Really. And this is not new cutting-edge technology here, we've had that capability for a good number of years now!
Even better, I can match up that information to what upstream actually publishes: if they say the bug I care about is fixed in version 3.1.4, I can upgrade to version 3.1.4. With distro packages, who knows? The distro might have backported the bugfix into 2.7.1 and bumped the patch number, for all I know. The more places I have to look to find out what's up-to-date and what versions I should use, the more opportunities I have to mess up. Reduce the number of places to look until it's one and only one: the upstream release notes, using upstream's versioning and upstream's packages.
Distro packages for the base OS, language packages for application and its dependencies. Deviate from this at your peril.
It's been a decade since I worked at such a tiny nascent company that all the software was written in just one language. Language packages almost never express dependencies on either system packages or other languages' packages, making "bootstrap to the point of being able to use all of the languages' toolchains" a manual process that lacks any guardrails. Nothing ensures you have a httpd version that's compatible with all your apps, because each of them just sort of assume httpd is out there somewhere without saying anything about it. Staying on the right versions of shared libraries is even more error-prone since the system package manager literally doesn't know you're using them.
If you want to read upstream security advisories and use such bleeding-edge software that even the bleeding-edge distros don't trust it yet, you're basically rolling your own distro that only exists on one machine in the world (because some languages' package managers aren't idempotent and symmetric) and is supported by nobody besides you. I'd rather delegate that to the people who specialize, because the best case is that I don't fuck it up too badly, I'll never add value that way.
By all means run the test server as an environment identical to production. I've never said you shouldn't. But people do have to locally run the code on their laptops to do dev work.
I don't care whether it builds or runs on a laptop
Good for you! Now, clean out your desk, because "build custom infrastructure to suit my workflow, but your workflow isn't important" is a clear admission that you don't ever get to work on my team, or probably anyone else's.
I don't write twitch games and interesting problems don't fit on a single machine anymore.
Ah, so you only will work on "interesting" problems, and literally all possible problems you don't find "interesting" are in categories like "twitch games", to be insulted and belittled. It's a good thing you were already fired a paragraph ago, because you'd get fired for that too; turns out most companies don't have problems you'd consider "interesting". So sorry for that, but them's the breaks.
It's been a decade since I worked at such a tiny nascent company that all the software was written in just one language.
With a head that big, what's your size in hats?
Language packages almost never express dependencies on either system packages or other languages' packages
But to actually respond: how many single applications do you think the average company has which are written in, say, five or more different languages and must deploy the entire codebase to a single machine? You know, that single machine you refuse to work with, because it must be just for a "twitch game" or some other tiny puny baby child's toy of a program.
If you want to read upstream security advisories and use such bleeding-edge software that even the bleeding-edge distros don't trust it yet
So sorry that I wanted to use the version with the feature that didn't make it in under the distro's freeze date. Guess we'll just wait ten years until the support contract expires and we're finally forced into an OS upgrade, then? Management will be very happy to hear that timeline, I'll bet they give you a promotion and a raise when they find out you're the one holding it up!
you're basically rolling your own distro that only exists on one machine in the world
I have reproducible builds using language packaging toolchains. Turns out it's 2017 and we can do that now.
I'd rather delegate that to the people who specialize, because the best case is that I don't fuck it up too badly, I'll never add value that way.
There are parts of this sentence that I agree with.
When I write java, I can't run maven in prod and expect it to get native libraries into /usr/lib64 and the sysadmins' Python and Go plumbing and config files into ... wherever the hell that may live. So together we tweak a .spec file that not only provisions the entire machine correctly but answers questions about whether the entire machine is provisioned correctly, not just the java half. (We probably could make maven do all that, but the result would be worse in every conceivable way, and in most languages it's not even an option.)
If you want a rolling release distro, use one. Godspeed. But nobody's going to sell a support contract that covers random alpha builds published overnight. "We can't upgrade the distro and get the code we need, so we're smuggling in code that the distro doesn't trust yet" is just devs and sysadmins playing chicken over the fate of the project. The bleeding-edge vs supported argument should have been settled before going live.
> "diamond" where you depend transitively on two different version of the same library
That's a trainwreck waiting to happen. It's not even worth testing, much less deploying.
Language package managers are a lot better at that than OS package managers, IME. Much better for all deploys of version x to use the same version than for all deploys to host y to use the same version.
Virtual environments tend to solve the problem in either case.