Originally posted by carewolf
View Post
Announcement
Collapse
No announcement yet.
Python 3 Is Close To Becoming The Default In Fedora 22
Collapse
X
-
RE: PEP-0394, Gentoo did this too. The python version that /usr/bin/python points to is user configurable, but defaults to python3 since early 2012.
There was a small amount of fallout, but thanks to users' ability to select python 3 as the default, the most serious issues had already been reported and addressed at that point.
Comment
-
Originally posted by Cyber Killer View PostThe whole problem with python3 adoption is the libs. A very high amount of libs still have not moved to py3, and are keeping the world on py2, make dev write apps for py2, write more libs for py2 etc...
I can see no reason to switch to Python3. Can you? (besides "it's new").
If Python2 is no longer developed, maybe a fork is justified.Last edited by Togga; 22 January 2015, 07:35 PM.
Comment
-
Originally posted by Togga View PostAnd the fact that python3 got worse, especially when used interactively. In python2 you have a nice distinction for instance between "map" and "imap", in python3 you need to write "list(map(fn,lst))" to see the result on the prompt or get a list.
I can see no reason to switch to Python3. Can you? (besides "it's new").
If Python2 is no longer developed, maybe a fork is justified.
Comment
-
Originally posted by Togga View PostI can see no reason to switch to Python3. Can you? (besides "it's new").
- utf8 - finally, maybe in the English speaking world this isn't a big deal, but in every eastern European country, that has it's own special characters in the alphabet, this is a killer feature - getting py2 to correctly support non-western characters is a major headache
- more functions instead of statements (with print being the biggest deal) make the syntax a lot more clear to anybody coming from other languages
note: I generally write in whichever language gets me what I want in the easiest and fastest way, so I'm not a python fan any more than I'm a fan of bash, php, ruby, lua, etc... but I find py3 a lot more convenient than py2, for my use when I want to write something in python
Comment
-
Originally posted by phoronix View PostPhoronix: Python 3 Is Close To Becoming The Default In Fedora 22
For Python stakeholders using Fedora, the Fedora 22 release is preparing to ship Python 3 as the one and only Python implementation on the installation media...
http://www.phoronix.com/scan.php?pag...ython-3-Status
Thanks for writing a nice article. Please note that as I've written in the sum-up mail, we most likely won't achieve completely Python2-free LiveCD, just mostly. Might be worth mentioning in the article, since it seems to suggest otherwise
Comment
-
Originally posted by Cyber Killer View PostOf course I do:
- utf8 - finally, maybe in the English speaking world this isn't a big deal, but in every eastern European country, that has it's own special characters in the alphabet, this is a killer feature - getting py2 to correctly support non-western characters is a major headache
- more functions instead of statements (with print being the biggest deal) make the syntax a lot more clear to anybody coming from other languages
note: I generally write in whichever language gets me what I want in the easiest and fastest way, so I'm not a python fan any more than I'm a fan of bash, php, ruby, lua, etc... but I find py3 a lot more convenient than py2, for my use when I want to write something in pythonLast edited by nanonyme; 23 January 2015, 04:37 AM.
Comment
-
Originally posted by nanonyme View PostPython2 supports utf-8 just fine.
Even in python shell scripts it's more or less ok with utf8 on Linux if you write the needed charset header in the file and you can use nonwestern chars, but as soon as you try it on windows, it breaks.
From my experience py2 and unicode don't mix. Period.
Comment
-
Originally posted by Cyber Killer View PostI've been working as a software tester on a couple of py2 based projects, they were webapps using django, twisted, etc... a typical testcase was: input japanese characters into a textfield, submit the form, so it gets saved into the db... and watch as the whole thing falls apart, when the devs fix this particular form, repeat with the next one cause it's going to be broken in the same way.
Even in python shell scripts it's more or less ok with utf8 on Linux if you write the needed charset header in the file and you can use nonwestern chars, but as soon as you try it on windows, it breaks.
From my experience py2 and unicode don't mix. Period.
Comment
-
Originally posted by Togga View PostAnd the fact that python3 got worse, especially when used interactively. In python2 you have a nice distinction for instance between "map" and "imap", in python3 you need to write "list(map(fn,lst))" to see the result on the prompt or get a list.
Originally posted by Togga View PostI can see no reason to switch to Python3. Can you? (besides "it's new").- Division is handled sanely without having to import from __future__
- No more long vs. int
- keyword-only arguments
- a, b, *c = (1, 2, 3, 4, 5) (this may be even more flexible in 3.5)
- Ranges are lazy (but still indexable), saving memory
- Dict methods use views, saving memory
- super() works
- __pycache__ and supporting multiple python version .pyc files and .so files
- yield from
- 0100 != 64
- statistics module
- Pool, popen, and assertRaises context managers
- pool.startmap
- unittest.assertWarns and unittest.assertCountEqual
- high-performance decimals
Stuff coming in 3.5:- math.nan and math.inf
- type annotations
Comment
Comment