Announcement

Collapse
No announcement yet.

The State Of Debian 9.0 Stretch

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #11
    Originally posted by DanLamb View Post

    ... even now, there isn't major missing features in Python 2.7.
    Proper Unicode handling, new-style objects, contextlib.ContextDecorator, sysconfig, venv, enum, selectors, statistics ...

    Oh yes, and coroutines.

    Comment


    • #12
      Originally posted by ldo17 View Post

      Proper Unicode handling, new-style objects, contextlib.ContextDecorator, sysconfig, venv, enum, selectors, statistics ...

      Oh yes, and coroutines.
      enums are back-ported to Python 2.7. Python 2.7 has virtualenv. "new-style objects"? Is that the OOP class thing? I'm pretty sure that works in 2.7.x too.

      Python 3 is better in that default `str` type supports unicode rather than separate str/unicode types like in Python 2.7.x, but Python 2.7.x does support Unicode.

      Coroutines are nice. I like the optional type annotations in Python 3.5+.

      None of the Python 3.x features are really killer features to compel upgrades, and many important ecosystems have prioritized Python 2.x.

      Comment


      • #13
        Originally posted by DanLamb View Post

        None of the Python 3.x features are really killer features to compel upgrades, and many important ecosystems have prioritized Python 2.x.
        I see a lot of Python wrappers for libraries bogged down by maintaining backward compatibility with 2.x. For example, PyCairo (binding for Cairo) has been neglected for many years, so I took the opportunity to create a new one (Qahirah) for Python 3.3 or later only. As a bonus, because it is written in pure Python, I was able to go beyond the capabilities that PyCairo was able to support (e.g. font handling) by writing much less code.

        Similarly, my D-Bus binding takes advantage of coroutines, which makes writing event-loop-friendly code much easier. Ever done much callback chaining? This lets you cut that code in half.

        Comment

        Working...
        X