I find it very easy to write code which is simultaneously Python 2 and 3. A few ``from __future__ import`` statements and you'll be fine. The only reason some people are complaining is that they were ignoring bugs in their code regarding text data. It's not a Python problem, it's a problem with computers -- bytes are not text, but many systems ignore the difference.
Many large enterprises are starting new projects in Python 3 exclusively. It's fine if you want to use some Python 3-only syntax.
No it's not. The syntax is what defines the language:
In linguistics, syntax is the set of rules,
principles, and processes that govern the structure
of sentences in a given language.
It doesn't have the same syntax. It's not the same language, by definition.When we say it's the same language, most of those aspects are the same from Python 2 to Python 3.
What impact does one or other way of thinking (absurd vs has merit) about this (a potential break in backward compatibility between language versions due to any addition, removal or alteration of one or more language features) have on the language and its ecosystem and culture?
Imo:
* such potential breakage is relatively benign iff there's an easy-to-follow technique (eg using a linting tool or a program editor's search feature) that always ignores/accepts code compatible with the older language version and always catches/rejects code compatible with the newer language version.
* a further improvement on this is to have the inter-version checking done by a language's interpreters/compilers.
* best of all is when the language is at least partly compiled and compilation using the older interpreter/compiler does the rejecting at compile-time.
But I do feel like tides are shifting and Python 3 is slowly "winning". It's just taking, what, almost a decade longer than most would have hoped?
"Ubuntu 15.10" - Python 2.7.10
"Ubuntu 14.04.4 LTS" - Python 2.7.6
Not sure where you're getting the "by default 3.5" from.
> python3 --version
Or: http://packages.ubuntu.com/xenial/python3But yes, the "now there are two ways to do it" brought on by 2 and 3 really sux.
I should also say I always hated the "small" syntax changes even between the point releases. This was also something that kept me away (ruby has this problem too). Perl never had this problem, stuff written in 2001 can still run on perl of 2016. But I see now that this is a double edge sword. I have worked for several companies that run modern perl versions but refuse to touch their code base that was written like it was 1998 because it just "still works". That was another reason I started looking into python. I very much welcome complete breakage every few years at this point. It will at least force people into staying modern with the stack they use instead of becoming a 15 year old fossil with a disgusting resume. (I mean, what would you do if someone sent a resume to your dev shop that said they have only done CGI perl for the last 15 years and have no idea what javascript is or why they should learn it?)
The biggest issue people are having is to convert their python 2 code to work on python 3. There's virtually no downside to use python 3. All maintained libraries work with python 3.