5 ms·
I think Python 2 had hit the perfect balance of "just enough but not too much" which I'm very deeply worried that Python 3 is going to deviate from.
by VectorLock 7y ago
I think Python 2 had hit the perfect balance of "just enough but not too much" which I'm very deeply worried that Python 3 is going to deviate from.
- novok 7y agoPython 3 is barely different in my experience and it's been about 10 years at this point. I do enjoy some of the "new" features of python 3.
- rabidrat 7y agoI used `async` as the name of a function decorator in some Python3.4 code, which then broke in 3.6 which introduced `async` as a keyword.
- zerkten 7y agoWhat was the level of effort to remediate that?
- takeda 7y agosed 's/async/whatever' ...
- rabidrat 7y agoProbably around 4-6 hours of work all told. We had to come up with a new name, do a find/replace, review the changes, test, fix a couple of issues because the replace wasn't perfect/complete, update the dev documentation, make a new patch release, and then create packages for the various supported platforms. Oh and looking back over it now, the filename had to be changed too, because apparently you can't use a keyword as a module name in Python either. So where the documentation linked directly to that file, that had to be updated as well. [1] https://github.com/saulpw/visidata/issues/164 https://github.com/saulpw/visidata/issues/164 [2] https://github.com/saulpw/visidata/releases/tag/v1.2.1 https://github.com/saulpw/visidata/releases/tag/v1.2.1
- VectorLock 7y agoSome of the syntax changes are barely different (print statement a function instead of a keyword, good) but a lot of new things are added that I would consider to be syntactic sugar (walrus operator, for example) that threaten to detract from the two biggest things that drew me to Python: clean syntax and obvious understandability.
- gowld 7y agoPython allows imperative code with side effects in imported modules, as well as the "else" statement for "for" loops, so Python has never guaranteed obvious understandability.
- VectorLock 7y agoSure there are plenty of things that aren't perfect in Python, but I think it was the best of all viable candidates that came closest to that goal.
- downerending 7y agoNot very different, but fallout from the Unicode switch is quite a headache. I generally run with LANG=C, and run into Python3 issues regularly as a result. Also, if you have to support 'async' code that someone wrote, that could be a heavy load as well.